What is this?
Douglas is a file-based blog system written in Python with the following features:
- WSGI application
- runs as a CGI script (woo-hoo!)
- plugin system for easy adjustment of transforms
- Jinja renderer
- basic set of built-in plugins
Douglas is a rewrite of Pyblosxom.
There are other file-based blog systems out there that have a more complete feature set. I continued this one because at the time, it was easier to continue working on this than to switch.
However, I've now switched to nikola. It's pretty swell. It was easy to switch my Pyblosxom/Douglas blog over.
Ergo, this project is dead for now.
- Python 2.7
- possibly other requirements depending on what plugins you install
Quickstart for compiling a new blog
Create a virtual environment
Activate the virtual environment
Install Douglas into your virtual environment:
pip install https://github.com/willkg/douglas/archive/master.zip#egg=douglas
Create a new blog structure:
douglas-cmd create <blog-dir>
douglas-cmd create blog
blog/config.pyfile. There should be instructions on what should get changed and how to change it.
Change directories to
blogand then render the site:
Collect the static assets:
compiled_site/directory tree to where they're available for serving by your web server.
Where to go from here
Each file in
blog/entries/ is a blog entry. They are text files.
You can edit them with any text editor.
The blog is rendered using Jinja2. The templates are in the
blog/themes/ directory. A theme consists of:
content_typefile which has the mimetype of the output being rendered (e.g.
entry.<themename>file which is used when rendering a page with a single entry
entry_list.<themename>file which is used when rendering a page with a bunch of entries (e.g. category list, date archive list, front page, ...)
- additional template files required by plugins as specified by those plugins
- static assets like CSS files, JS files and images in the
The following plugins which come with Douglas are enabled by default
load_plugins config property:
Creates a draft folder that you can view on the web-site, but doesn't show up in the archive links. This makes it easier for other people to review entries before they're live.
The draft dir is
When you want to make an entry live, you move it from
#published YYYY-MM-DD HH:MMto the metadata in your blog entries. That's the published date for the blog entry rather than the mtime of the file.
Douglas comes with other useful plugins. Refer to the documentation for a list.
You can write your own plugins and put the plugin files in
blog/plugins/ and add the plugin Python module to the
load_plugins list in your