Rendering Time plan / Gantt charts: hourgraph
I have a number of tools and other programs I've implemented, but forgotten to blog about here - hourgraph is one such tool I stumbled across today again. Originally I implemented it for my PhD panel 1 topic project analysis report, as I realised that not only have I manually created a number of these, but I'm going to have to create a bunch more in the future, but I open-sourced it as I usually do with most of the things I write in the hopes that someone else will find it useful.
I've published it on NPM, so you can install it like this:
npm install --global hourgraph
You'll need Node.js installed, and Linux users will need to prefix the above with
The program takes in a TOML definition file. Here's an example:
width = 1500 height = 480 title = "Apples" [[task]] name = "Pick apples" start = 0 duration = 3 [[task]] name = "Make apple juice" start = 2 duration = 2 [[task]] name = "Enjoy!" start = 4 duration = 4 colour = "hsl(46, 90%, 60%)" ghost_colour = "hsla(46, 90%, 60%, 0.1)"
The full set of options are available in the default config file, which is loaded in to fill in any gaps of things you haven't specified in your custom file.
Comprehensive usage instructions are found in the README, but you can render a new time plan chart thingy like this:
hourgraph --input path/to/input.toml --output path/to/output.toml
The above renders to this:
Personally, I find it's much easier to create charts like this by defining them in a simple text file that is then rendered into the actual thing. That way, I don't have to fiddle with the layout myself - it all comes out in the wash automatically.
For those interested in the code, it can be found here: https://github.com/sbrl/hourgraph