static site generator
Lightning is a static blogging engine designed to make it painless to author and
update large blogs.
git clone [email protected]:borismus/lightning.git
cd lightning
to get to your newly cloned repository.pip install -r requirements.txt
.Build your site by running ./lightning in the current working directory. This
will read your lightning.yaml and go from there.
I used livereload to build a preview script:
#!/usr/bin/env python
from livereload import Server, shell
server = Server()
server.watch('content', shell('../lightning/lightning -o www'))
server.serve(root='www')
And host my static site on github pages, which I deploy to using this script:
#!/usr/bin/env sh
DEPLOY_PATH=/Users/smus/Projects/smus.com-deploy
# Do a deploy build to the smus.com gh-pages repo.
../lightning/lightning --out=$DEPLOY_PATH
# Commit the updated contents there, and push it upstream.
pushd $DEPLOY_PATH
git add -A
git commit -m "Updating smus.com with new content."
git push origin gh-pages
popd
lightning.yaml
specifies where to look for content, template and where
to dump output.
site.yaml
specifies metadata about the site itself.
An example site can be found in the example directory of this repository.