This repository is rather large (about 200MB at the time of writing) because everything (including images) is included. The initial cloning therefore takes a few seconds (depending on your Internet connection).
Please have a look at our contribution guidelines.
We have a Docker build container 'cause it's hip, but you may also roll your own environment. Choose as you like.
experimental
docker run --rm=true -e DEVUID=$(id -u) -p 127.0.0.1:8000:8000 -v $(pwd):/home/dev raumzeitlabor/rzl-homepage-dev-docker
sudo apt-get install nodejs nodejs-legacy npm bundler ruby-dev
sudo npm install -g grunt-cli
sudo pacman -S nodejs npm
gem install bundler
sudo npm install -g grunt-cli
sudo pkg install node npm rubygem-bundler nasm
sudo npm install -g grunt-cli
Note: nasm(1) is needed to compile some node packages from source.
Needs Homebrew.
brew install node ruby
sudo gem install bundler
sudo npm install -g grunt-cli
yarn install
bundler install
grunt serve
$EDITOR app/$file
grunt
uses the default task in the Gruntfile to build the whole site
(targets test
and build
). This is what Travis does on new commits (see
.travis.yml).
You can also run individual Grunt targets, e.g.
grunt build
grunt test
To check the result use
grunt serve:dist
which rebuilds the whole project and serves the "dist" folder on port 8080
.
The editing of files then triggers a new build.
You can read about all targets in the Gruntfile.
This homepage is auto-deployed by Travis if the following requirements are met:
Travis will rsync the contents of the dist directory to citizenfour (this is really fast). Please note that it may take a few minutes until Travis is able to complete a build. We originally used Travis' new container-based infrastructure; due to lack of IPv6 (we deploy via IPv6) we had to switch back to the standard virtualized boxes, leading to a much slower build.
The homepage is served by the rzl-homepage-docker container. Anything related to webserver setup should be filed against that repository.
The data flow is as follows:
app
app/_layouts |
| v
v +--------+
.layouts -> | jekyll | -> .tmp -> dist
+--------+
The Gruntfile we're using was initially generated using the yeoman webapp generator. While it allows for really nice development setups, it is a bit complicated to understand. Here's some information on how the homepage is built (rough sketch):