Build Status Coverage Status

This is the code used to write, build, test, and deploy my personal website and blog. The code was originally based on a great blog post by @n1ko, but has since diverged from that project quite a bit. If you're looking for his work, you can check that out Notable changes from his version: the use of docopt, testing, and python packaging for installation of the sitebuilder script. The javascript and visual design of the site are still almost exactly his.

In the spirit of his generosity and in the hopes it might be useful to others, I'm open sourcing my version of it as well.


This repo is a static website builder/generator implemented in Python using the following tools:


Note: you need a working installation of Python and pip. I've recreated the sitebuilder script as a python package, so you can install it in your virtualenv.

$ git clone blog
$ cd blog
$ git submodule update --init --recursive 
$ virtualenv --no-site-packages `pwd`/env
$ source env/bin/activate
(env)$ pip install -r requirements.txt
$ pip install -e .

That'll get you up and running. Use -h from the command line for options.


I've customized deployment steps to push directly to an s3 bucket configured to serve my site. It works for me, but YMMV. This area of the code is probably the least generalizeable section, so caveat emptor.

Also, see the License section of this document for more information about contents copyright.


The command is installed in the package and is the entry point into the entire system

To serve the website locally (optionally in DEBUG=True mode):

$ ./ serve --debug
* Running on
* Restarting with reloader

This is useful when you want to see changes without having to rebuild the whole site.

To build the static website:

$ build

Generated HTML files and assets will go to the ./build/ directory.

To deploy the website

$ deploy

There's also a command for creating a post:

$ new --title="My title"
$ Created pages/drafts/
$ cat pages/drafts/
title: My title
date: 2013-04-22
published: False
type: post


Contents in ./pages (blog posts) are licensed under the terms of the Creative Commons BY-NC-SA license.

All the rest including Python code, templates, CSS & JavaScript is released under the terms of the WTFPL.

  • This code won't especially be maintained for other purpose than my own needs.


  • [] Double included static directory included in freezer.all_urls()
  • [] Get build to skip things that aren't needed (unminifed css/js)
  • [] Clean up assets, get .styl build working.
  • [] Change layout so article pane is more of the screen (move sidebar left)
  • [] Coffeescript?
  • [] Increase coverage
  • [] Continuous delivery