FORTUNE(6-BSD) RISC/os Reference Manual FORTUNE(6-BSD)
NAME
fortune - print a random, hopefully interesting, adage
SYNOPSIS
/usr/games/fortune [ - ] [ -wslaod ] [ file ]
DESCRIPTION
fortune with no arguments prints out a random adage. The
flags mean:
-w Waits before termination for an amount of time calcu-
lated from the number of characters in the message.
This is useful if it is executed as part of the logout
procedure to guarantee that the message can be read
before the screen is cleared.
-s Short messages only.
-l Long messages only.
-o Choose from an alternate list of adages, often used for
potentially offensive ones.
-a Choose from either list of adages.
-d Dump the table information. This gives information
about which file was read, the sizes of the adages, the
internal state, and the file that was written (see
below).
In order to cause fortune to be random, the program must
store a table in a file. By default, this information is
stored in the data file, but this can cause the data file to
be backed up all of the time. In order to defeat this, if
the file /usr/games/lib/fortunes.tbl exists and is owned by
daemon, it is used as the table file. If the file is empty,
the table is read from the standard file, but the table will
be written to the alternate file. The result is that there
is a 28-byte file that gets backed up instead of a 400Kbyte
file.
The user may specify a file of adages. This file must be
created by the program strfile, which is only available with
the fortune source, and be given by the user as file. Only
one such file may be named, subsequent ones are ignored. In
addition, this defeats the use of the alternate table file.
FILES
/usr/games/lib/fortunes.dat
Data file
/usr/games/lib/fortunes.tbl
Printed 1/15/91 Page 1
FORTUNE(6-BSD) RISC/os Reference Manual FORTUNE(6-BSD)
Alternate table file
AUTHOR
Ken Arnold
Page 2 Printed 1/15/91