I have been using display-dhammapada for some time now but I have always wanted a similar program for zen koans.
From there I added 2 more koan collections, The Gateless Gate and The Blue Cliff Record, and wrote a wrapper script for these collections.
The wrapper script, “zen” has several options including printing to the terminal (similar to fortune or display-dhammapada), formatting the output to html, to be included in a web page, and printing the output to ~/koan.html to be viewed in firefox (or other browser).
For an example of the script on a web page see : tenach’s blog (thank you tenach for putting this up).
When printing to ~/koan.html , there are several themes.
Assuming you have downloaded zen-koans.tar.gz to ~/Downloads, you can either extract the file with a graphical tool (Archive Manager) or the command line.
tar xzvf zen-koans.tar.gz
Detailed instructions, and a description of the options, are included in the README.
To install on Ubuntu (Instructions for Fedora are in the README):
#copy the perl modules
sudo mkdir -p /usr/local/share/perl/5.10.1
sudo cp -R Zen-Koans/Zen /usr/local/share/perl/5.10.1
#copy the images
sudo mkdir /usr/local/share/images
sudo cp Zen-Koans/images/* /usr/local/share/images
#copy the wrapper script
sudo cp Zen-Koans/bin/zen /usr/local/bin
sudo chmod +x /usr/local/bin/zen
To try out the application try:
zen -ab && firefox ~/koan.html
For additional options , help is available with the -h flag:
bodhi@maverick:~$ zen -h This program prints a random koan form one of 3 collections of koans : Shaseki-shu (Collection of Stone and Sand) - Default The Gateless Gate The Blue Cliff Record The Shaseki-shu koans are easiest to comprehend, The Gateless Gate are intermediate, and The Blue Cliff are most difficult. The default behavior is to print to the terminal usage: zen [options] -h | --help : this (help) message. -c | --cliff : Use the Blue Cliff Record. -g | --gate : Use the Gateless Gate. -a | --about : Print information about the collection (first koan). -i | --include : Prints the koan with (basic) html formatting. -b | --buddha : Prints the koan to ~/koan.html , view with firefox. -f | --forest : Same as -b, forest BG image. -s | --stones : Same as -b, zen_stones BG image. -y | --yinyang : Same as -b, yin-yang BG image. -d | --dark : Prints to ~/koan.html , dark BG, no image. -l | --light : Prints to ~/koan.html , light BG, no image. -o | --gold : Prints to ~/koan.html , gold BG, no image. -r | --random : Prints to ~/koan.html , random koan/theme.
I hope you enjoy them =)
Be careful, I am afraid they can be addicting.
If anyone would like to offer improvements or help package them into a ppa , assistance would be appreciated (pm me on the Ubuntu Forms). Otherwise I will try to package them into a ppa as time allows.