chronicle1
A simple blog compiler.
Usage
chronicle [options]
About
Chronicle is a simple tool to convert a collection of text files,located within a single directory, into a blog consisting of staticHTML files.It supports only the bare minimum of features which are requiredto be useful:* Tagging support.* RSS support.* Archive support.The obvious deficiencies are:* Lack of support for instant commenting.* Lack of pingback/trackback support.Having said that it is a robust, stable, and useful system.
Blog format
The format of the text files we process is critical to the outputpages. Each entry should look something like this:
Title: This is the title of the blog postDate: 2nd March 2007Tags: one, two, three, long tagThe text of your entry goes here.
NOTE: The header MUST be separated from the body of the entry by at least asingle empty line.In this example we can see that the entry itself has been prefacedwith a small header. An entry header is contains three optional lines,if these are not present then there are sensible defaults as describedbelow.The formatting of the output dates may be changed via the use of theB<--lang> command line option (or the matching "lang=french" option in theconfiguration file), but the date of the entry itself should be specified inEnglish.
- Title: Describes the title of the post. If not present the filename of the entry is used instead. "Subject:" may also be used.
- Subject: This is a synonym for 'Title:'.
- Date: The date the post was written. If not present the creation time of the file is used instead.
- Publish: This header is removed from all entries, and is used by the chronicle-spooler script.
- Tags: Any tags which should be associated with the entry, separated by commas.
The format of the entry is assumed to be HTML, however there is supportfor writing your entries in both textile and markdown formats.The format of entries is specified via the B<--format> argument, orvia a "format: foo" setting in your chroniclerc file.The format of entries is assumed to be global; that is all your entrieswill be assumed to be in the same format. However you can add a"format: foo" pseudo header to specific entries if you wish to writespecific entries in a different format.To allow flexibility in the handling of entries each blog entry willbe passed through the filter script B<chronicle-entry-filter>which allows you to modify this handling in a single location. Thisscript allows entries to be updated via filters both before and afterthe conversion to HTML. For further details please see the manpage forthat script.
Configuration
The configuration of the software is minimal, and generally performedvia the command line arguments. However it is possible to save settingseither in the file global /etc/chroniclerc or the per-user ~/.chroniclercfile.If you wish you may pass the name of another configuration file tothe script with the B<--config> flag. This will be read after theprevious two files, and may override any settings which are present.The configuration file contains lines like these:
input = /home/me/blogoutput = /var/www/blogformat = markdown
Keys which are unknown are ignored.
Optional caching
To speed the rebuilding of a large blog the compiler may use a localMemcached daemon, if installed and available.To install this, under a Debian GNU/Linux system please run:
apt-get updateapt-get install memcached libcache-memcached-perl
You may disable this caching behaviour with --no-cache, and see theeffect with --verbose.
Optional calendar
If the 'HTML::CalendarMonthSimple' module is available each blog willcontain a simple month-view of the current month upon the index.To disable this invoke the program with '--no-calendar'.
Optional commenting
Included with the chronicle code you should find the filecgi-bin/comments.cgi.This file is designed to write submitted comments to the localfilesystem of your web-server. If you install that, and edit thepath at the start of the script you should be able to includecomments in your blog.In short there are three things you need to do:
- Install the CGI script and edit the path at the start.
- Copy the output comments to your local blog source.
- Run this script again with --comments=./path/to/comments
This should include the comments in the static output. Moreexplicit instructions are provided within the file 'COMMENTS'included within the distribution.
Releases
8 releases since Debian 5.0 (Lenny); the text changed 3 times.