Skip to content
Switch branches/tags

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

Twitter Haiku

Twitter Haiku is a set of small scripts that produce a pdf with haikus from Twitter. It pulls 50 recent tweets marked with the hashtag #haiku, discards the ones that don't look like haikus and prettifies the rest. It also discards duplicates (usually retweets). Tweet manipulation is handled by ruby while LuaTeX and ConTeXt take care of the typesetting and pdf generation.

Running the scripts

There are Rake tasks that take care of fetching the twitter feed, normalizing it, building the pdf file and running the tests. Ruby and Rake are required to run the tasks.

The following tasks are available:

rake build      # Build the pdf file
rake clean      # Remove generated pdf and temporary files
rake fetch      # Fetch a fresh twitter feed
rake prepare    # Rewrite the twitter feed by normalizing tweets
rake test       # Run tests

To get a fresh pdf file from scratch:

$ rake

If ruby and rake are not available it is still possible to generate the pdf file manually:

$ context haiku.tex

Installing LuaTeX

Depending on the availability or lack of packages for your platform of choice it may not be the easiest task. Contextgarden might be a good start.

About the project

Written by Miha Filej for the course Typographic programming taught by Petr Sojka at FI-MUNI.


Haikus from twitter to pdf with luatex and ruby



No releases published


No packages published