[1221] in linux-announce channel archive
Modified BSD fortune
daemon@ATHENA.MIT.EDU (Lars Wirzenius)
Sun Oct 29 11:31:00 1995
Date: Tue, 24 Oct 1995 20:37:19 +0200
From: Lars Wirzenius <wirzeniu@cc.helsinki.fi>
To: linux-announce@vger.rutgers.edu
Reply-To: linux-announce-owner@vger.rutgers.edu
From: Amelia A Lewis <alewis@email.unc.edu>
Subject: Modified BSD fortune
Approved: linux-announce@news.ornl.gov (Lars Wirzenius)
Newsgroups: comp.os.linux.announce
Followup-to: comp.os.linux.development.apps
Organization: ?
-----BEGIN PGP SIGNED MESSAGE-----
I have uploaded a modified version of the BSD fortune program to sunsite.
It is currently in /pub/Linux/Incoming, but will probably be moved to
/pub/Linux/games at some point.
This version began as solely a bug-fix, but acquired a certain number of
enhancements on the way. See the README below for details.
The remainder of this message is the contents of the fortune-mod.README
file and the fortune-mod.lsm file.
Amy!
- --README--
This version of fortune is a modification of the NetBSD fortune, as
tweaked by Florian La Roche (see below, and many thanks to Florian for
starting the update), and then massively hacked on by Amy Lewis.
I (Amy) hacked on this because it was broken; the BSD source itself is
broken (I looked at it). Specifically, if you are using an old version
of fortune, then it accesses *only* the two files "fortunes" and
"fortunes-o", even though 'fortune -[ao]f' will tell you differently.
That was my original reason to start working with the code.
Bug fixes: fortune now reads the same file list that it reports with -f.
strfile now really sorts and randomizes, instead of just setting the
'sorted' and 'randomized' flags. strfile does not lose the pointer to a
fortune that follows a null fortune.
Enhancements: fortune -f now prints percentages, whether specified on the
command line or not. fortune -m now prints filenames to stderr; the
fortunes printed to stdout can be redirected into a file which is valid
strfile format. fortune -l|s can be modified with -n _number_ to specify
the number of characters in a short fortune (default 160, as before).
The means of distinguishing between offensive and inoffensive fortunes is
changed: offensive fortunes are put in a separate subdirectory. The
contents of the fortunes databases have been extensively reviewed, and
broken into smaller, more manageable [hopefully] files.
strfile is not notably enhanced, though it received the most significant
bug fixes. unstr now accepts a command line parameter -c _char_ which
globally changes the delimiter character. unstr now accepts an output
file as the second file parameter, and can tell if a file has a '.dat'
extension.
An example of the use of fortune-style databases for other purposes,
called randstr, has been added. See util/README.randstr
The Makefiles have been extensively hacked upon.
Bugs: combining -a with xx% filename, when _filename_ is found in both
the offensive and the inoffensive directories, causes fortune to exit
without an error message. I think it's confused as to which file gets
the xx%. I should fix this. Don't hold your breath, though.
For more information, see the files ChangeLog, Offensive, README.install,
and cookie-files in the top-level directory, and the comments in the
various *.c source files.
Amy A. Lewis alewis@email.unc.edu October, 1995
- ----Florian's README.LINUX---
I have looked at sunsite and tsx and found one very old fortune program
and one in the debian Linux distribution. But comparing that one with
the version in NetBSD-current showed me, that NetBSD-current has fixed
so many speeling-bugs that I just had to repackage everything for the
Linux community.
In the source package are all changes for Linux in the file LINUX.DIF.
(Rewriting the Makefiles and some trivial small fixes.)
I expect this "fortune.tar.gz" to show up under /pub/Linux/games.
Not only the kernel needs speeling-corrections,
Florian La Roche florian@jurix.jura.uni-sb.de April 1995
- --lsm--
Begin3
Title: fortune - BSD modified
Version: October '95
Entered-date: 01OCT95
Description: Bug-fixes and enhancements to the standard BSD fortune,
strfile, and unstr. Datafiles cleaned up. Added randstr.
fortune displays a random text string from a set of files
in a certain format; strfile and unstr maintain those files.
Keywords: fortune,games,database
Author: multiple
Maintained-by: alewis@email.unc.edu
Primary-site: sunsite.unc.edu /pub/Linux/games
665 bytes fortune-mod.lsm
3036 bytes fortune-mod.README
1311 Kb fortune-mod.tar.gz
Alternate-site:
Original-site:
Platforms: Linux
Copying-policy: BSD
End
Amy A. Lewis | Would that my hand were as swift as my tongue.
alewis@email.unc.edu | -- Alfieri
-----BEGIN PGP SIGNATURE-----
Version: 2.6.2i
iQCVAwUBMI0vhIQRll5MupLRAQFxvgQAxnR6W2osx6V1PM46VK1H7gMPg0jpWT/C
NnOBf1VuHoRShcwDekq1l3V9UtimGW8Hcr4Px0J0sUZCA3AwOxbi026rgU8zKb5a
z3RpPCbFqZgO7e9P4ih/HWu3PwPIJD65s09pX6BLoJKCkfLmefG53HLMuLEYj9Yc
JwtM3XLWFUY=
=Sgmn
-----END PGP SIGNATURE-----
--
This article has been digitally signed by the moderator, using PGP.
Finger wirzeniu@kruuna.helsinki.fi for PGP key needed for validating signature.
Send submissions for comp.os.linux.announce to: linux-announce@news.ornl.gov
PLEASE remember a short description of the software and the LOCATION.