tfortune - Fortune Cookies with Tags

tfortune logo

Like fortune(1), tfortune is a Unix command line utility which prints a random epigram. Epigrams are stored as plain text files, but they must be annotated with tags to make full use of the features which tfortune offers over other implementations.

Tfortune has a built-in matching language for epigrams. User-supplied tag expressions define subsets of admissible epigrams. If a tag expression is given, epigrams are picked from the admissible subset only.

Besides printing random epigrams, tfortune supports a number of other subcommands which help to maintain epigrams and tag expressions. There are subcommands for listing and for editing the input files, and for printing statistics about epigrams, expressions and tags. A subcommand that enables bash command line completion is also included.

Resources

License

Open source, licensed under the GNU GPL version 3 (GNU General Public License, Version 3)

Documentation

All parts of tfortune are well documented and illustrated with examples. See the manual page for details.

Programming Language

Plain C.

Dependencies

A working C compiler and a couple of other dependencies, most of which are standard (autoconf, make, m4, flex, bison). The notable exception is the lopsub library.