simple tiny document generator
Homepage Repository PyPI Python
pip install redtape==1.2
This is the source for the https://about.gitlab.com/ site. For a guide on how to start editing the website using git, see the handbook page on that topic.
Read how to preview any changes locally.
Edit data/team.yml and add a new entry for yourself (or
update the placeholder with your initials).
Images should be square, and should be uploaded to source/images/team.
Edit data/pets.yml and add a new entry.
Images should be uploaded to source/images/team/pets.
/applications)This link appears at the top of the homepage and can be used to promote new versions or upcoming events.
Edit data/promo.yml to update the link and text
properties.
/features)How to update the features page.
/comparison)How to update the comparison pages.
/release-list)How to update the release list page.
/handbook/engineering/projects)How to update the projects page.
How to add a press release page.
Before building the static files, ensure you have a GitLab.com PRIVATE_TOKEN
environment variable setup. This is required so that Middleman can automatically
build the direction page.
bundle install
bundle exec rake build
# To also build PDFs:
bundle exec rake pdfs
The above command builds the static files and PDFs into the folder public.
There are a few custom, static generators specified in config.rb. For
example, there are generators that produce the direction issue list,
release list, and organization chart dynamically.
These pages cannot be viewed directly via the Middleman server (e.g. http://localhost:4567) because there are explicit rules that tell Middleman to defer the generation to other scripts. These special URLs (e.g. /release-list/index.html) usually have two Middleman keywords:
This tells Middleman to output a static file based on the provided template.
This tells Middleman server not to handle this URL. The external generator will build the static files.
To preview these custom-generated pages locally, you must first rebuild the files:
bundle exec middleman build
To test out the site, you must run another Web server from the
public directory:
(cd public; python -m SimpleHTTPServer 8000)
This will start a Web server on port 8000 (you may omit the port number). You can preview the site by pointing your browser to http://localhost:8000.
Thanks to the Review Apps, the www-gitlab-com project supports live reviewing
of any website changes with every merge request. When a branch is pushed and
the pipeline is successfully run, you can see a link pointing to the live
environment in your merge request. The URL will be of the following scheme:
<branch-name>.about.gitlab.com.
Beware that:
www-gitlab-com repository. That means that branches from forks will not
deploy a Review App (hence MRs from contributors). For that case, you should
have at least Developer access to the www-gitlab-com project or
gitlab-com group.In case someone forgot the most important commands and is catting this file from the command line we end by listing them:
kill -kill `lsof -t -i tcp:4567`
bundle exec rake new_post
open -a "Google Chrome" http://localhost:4567
bundle exec middleman
or to execute the last two commands just run:
bin/run