Iris is a weblog application written in Python 2. The application footprint is extremely minimal, making it very easy to setup and use. In fact, Iris is just a single 39 line file: feed.py.
You'll need to create a homepage for your weblog called index.html
where you'll write your entries. The format of this is up to you, apart from two stipulations which enable Iris to work:
<title>Weblog Name, by Author Name</title>
<div title="7 July 2009, 20:51">
...
</div>
Of course, Weblog Name, Author Name, and 7 July 2009, 20:51 are all variables. You have to follow this date format, but of course it's configurable in the code. Once you've created an index.html
file with this format, all you have to do is install feed.py
in the same directory:
$ wget -O feed.atom.cgi http://inamidst.com/whits/code/iris/feed.py $ chmod 755 feed.atom.cgi
You'll need to have CGI scripts enabled and so forth, of course. What feed.atom.cgi
does is to provide the Atom feed for your site by parsing index.html
. When you want entries on index.html
to be archived, you just move them out of the file yourself to an archive page.
So a complete index.html
file might go something like this:
<!DOCTYPE html> <title>John's Crazy Weblog, by John Smith</title> <link rel="alternate" type="application/atom+xml" href="feed"> <h1>John's Crazy Weblog</h1> <div title="7 July 2009, 20:58"> <p>Welcome to my weblog!</p> <p>This is a weblog about crazy things.</p> </div>
This is a handy mechanism because if you miss out the title or get the date format wrong, Iris just skips the entry. So you can create drafts easily just by publishing them without the title attribute.
When you go to fill in the title, sometimes it's a bit cumbersome to fill it in by hand. You can add the following to your shell startup script:
alias now='echo $(date "+%e %B %Y, %H:%M")'
And then you can just run it and copy its output to fill in the title.
Iris is not released under any software license, but you're still generally free to use it. In the United States, for example: “Once you've legally downloaded a program, you can compile it. You can run it. You can modify it. You can distribute your patches for other people to use.”