1 # SPDX-License-Identifier: GPL-2.0
4 [supercommand tfortune]
5 purpose = fortune cookies with tags
7 Like fortune(1), tfortune prints out a random epigram. However,
8 the epigrams in the input files must contain additional information,
9 called "tags". The program picks only epigrams which are considered
10 "admissible" based on the tags and the command line options.
12 non-opts-name = <file>...
15 summary = epigrams which contain this tag are admissible
16 arg_info = required_arg
21 This option may be given multiple times.
25 summary = epigrams which contain this tag are inadmissible
26 arg_info = required_arg
31 Like --accept, this may be given multiple times. See the discussion
32 below how --accept and --reject interact.
36 summary = print tags found in input files
38 If this option is specified, tfortune does not print any
39 epigrams. Instead, it prints all tags found in the given input file(s),
40 together with how many time each tag occurred. The list is sorted by
43 [option accept-reject]
44 summary = Admissible epigrams
47 tfortune picks a random epigram from the set of admissible epigrams,
48 which is computed as follows. If neither --accept nor --reject are
49 specified, all epigrams are considered admissible. If only --accept
50 is specified, epigrams with at least one tag given as an argument to
51 --accept are admissible, all others are inadmissible. Similarly, if
52 only --reject is specified, epigrams with at least one tag given as an
53 argument to --reject are inadmissible, all others are admissible. If
54 both --accept and --reject are specified, an epigram is admissible
55 if and only if it has at least one tag which is given as an argument
56 to --accept but no tag which is given as an argument to --reject.
59 summary = Input file format
62 Input files may contain arbitrary many epigrams. The end of each
63 epigram must be marked with a "tag" line. The tag line consists of
64 four dashes, a space character, and a comma separated list of tags.
65 Tags may span multiple words, but no comma is allowed.
69 The following is an example input file for tfortune. It contains a single epigram
74 Anyone who attempts to generate random numbers by deterministic means
75 is, of course, living in a state of sin. -- John von Neumann
84 Copyright (C) 2016-present Andre Noll
86 License: GNU GPL version 3
88 This is free software: you are free to change and redistribute it.
90 There is NO WARRANTY, to the extent permitted by law.
93 .MT <maan@tuebingen.mpg.de>
98 .UR http://people.tuebingen.mpg.de/~maan/tfortune/