Debian Codegraph @

ChangeLog

raw
1 (Note: this file has been re-arranged to be in reverse chronological
2 order, which is The Right Thing for ChangeLogs - DLC)
3
4 March 05, 2004 (fortune-mod-1.99.1)
5
6 Most of the changes have occured at some point in time in the last
7 5 years.
8
9 A high number of spelling, punctuation, formatting and grammar
10 fixes.
11
12 Internationalisation support.
13
14 New -c option to see which file a fortune came from.
15
16 August 29, 1997
17
18 Incorporated a couple of minor changes made in the (old) Debian
19 fortune-mod package, including the addition of an extra data file
20 called 'cookie'. Renamed some documentation files, and included some
21 install information for non-Linux users. Added a "-v" option to
22 report the program version.
23
24 I intend to submit this distribution to SunSITE RSN.
25
26 -- Dennis L. Clark <[email protected]>
27
28 May, 1997
29
30 This release fixes many of the portability problems with the
31 fortune-mod program released by Amy Lewis in October, 1995. The
32 previous version had many Linux-isms in it, which left it unworkable
33 on any other platform. This version replaces most of these with more
34 standard calls, making it more likely to work under other platforms.
35 The Makefiles have been modified so that GNU's gcc and make are no
36 longer required: any standard make and ANSI-compatible C compiler
37 should work. Sorry, pre-ANSI compilers are not supported (c'mon, this
38 is the 90's, darn it!)
39
40 This version has been tested to work on SunOS 4.1.x as well as Linux.
41 All changes made to the sources were as platform-independant as
42 possible. Therefore, no "#ifdef LINUX" or "#ifdef SUNOS4" directives
43 appear in the code. An effect of this is that a number of 'implicit
44 declaration' warnings are emitted by gcc under SunOS 4.1.x, but this a
45 problem with SunOS's standard headers, not with the program or the
46 compiler. The benefit of this approach is that it eases the work of
47 expanding the port to include other platforms. Bug reports and fixes
48 for other platforms are most welcome!
49
50 A few "standard" C function calls were replaced with more standard
51 counterparts at various points. Generally, when there was a choice
52 between a BSD version of a function and a POSIX version, the POSIX
53 version was favoured (even though fortune originated on BSD). An
54 exception to this was the regex functions: either POSIX or BSD
55 versions can be used, with selection made via the top-level Makefile.
56
57 Fortune and strfile also compiles on Solaris 2.5, but a discrepency
58 between the declaration and implementation of 'struct dirent' on the
59 test platform caused fortune to execute incorrectly there. It is not
60 certain whether this is a bug in the header file, the C library, or
61 the test platform.
62
63 While the making of this release was not meant to become a bug
64 search-and-destroy mission, some bugs were inadvertantly discovered
65 and fixed. including the known bug of using -a with a file that occurs
66 in both the offensive and inoffensive directories. Fixing this
67 particular bug required a way to be able to seperately identify two
68 fortune files with the same name, with one in the inoffensive
69 directory, the other one in the offensive directory. Now, such a name
70 will be taken to be the inoffensive file by default. However, you can
71 now append '-o' to a fortune name, and the '-o' will be removed and
72 the offensive directory will be searched. Thus you can say (assuming
73 you use the distributed datfiles):
74
75 fortune 80% politics politics-o
76
77 Which has an 80% change of giving an "inoffensive" political fortune,
78 and a 20% change of giving an "offensive" political one. Note that
79 this makes fortune-mod backwards-compatible with BSD fortune, but only
80 for users, not fortune database maintainers.
81
82 Of course, this solution only passes the buck: with the above example
83 again, if you have a 'politics-o' file in your inoffensive directory,
84 you are back to square one. OTOH, seeing that '-o' originally was
85 meant for offensive fortunes, using it for inoffensive ones is simply
86 asking for trouble.
87
88 Bug fixed: Fortune's definition of a fortune length (for -s and -l)
89 was inconsistant. Unordered fortunes counted the 2 delimiting
90 characters (as hinted in the man page), but sorted or randomized
91 fortunes did not. Now the delimiting characters are _NEVER_ counted,
92 so you will always get the length limit you expect.
93
94 Another bug fix: -l and -s can now work together with -m. Previously
95 -l and -s were ignored when -m was in effect. The new behaviour helps
96 me count how many long or short fortunes there are in a file.
97
98 Ansify has been removed from the package, as well as some filter
99 scripts from NetBSD that no longer appear useful. Randstr has been
100 kept, but has not been improved in any way. It at least has a man
101 page: maybe somebody will find it useful.
102
103 Some of the documentation (including the man pages) has been improved
104 and updated, and some files have been renamed so that the package
105 looks less Linux-specific.
106
107 -- Dennis L. Clark <[email protected]>
108
109 Late October 1995
110 Ansify has been abandoned. I'm going to distribute this working version
111 of fortune, and then see how difficult it would be to add termcap/terminfo
112 enhancements to fortune itself--I don't anticipate serious problems, but
113 I'd rather go ahead and get this on the net.
114
115 A last-minute change was made to the way that percentages are displayed
116 with -f; it is now in the format nnn.nn%. The reason for this is that
117 with the multiplication of small files, fortune -af displayed a large
118 number of "0%"s--no worse than the old version, but not helpful.
119
120 The fortunes database was finally cleaned up, and this version is now
121 being distributed (at least, I hope it is). I don't consider the current
122 division of fortunes among files absolutely canonical; some are certainly
123 in the wrong places. But things are *better*.
124
125 Amy A. Lewis [email protected]
126
127 Mid-October '95
128 Another utility, ansify, now compiles; it has not been tested at all, so
129 it may not work even slightly.
130
131 Ansify is a rather stupid program, all things considered, but the work on
132 it does raise an interesting possibility for an enhanced fortune. At
133 present, the fortune databases contain x^Hy sequences for underline and
134 special characters (and this can be extended to include bold, = x^Hx).
135 Ansify is stupid because it doesn't use the proper tools, ie termcap or
136 terminfo (hmmm ... since it works on files, that may not be so stupid);
137 it appears that if that can be done, then a termcap/terminfo enhanced
138 fortune could be produced, which would recognize the existence of ^H in
139 a string and attempt to display using appropriate control sequences.
140 This sort of modification would be of greater interest to casual users,
141 I think, than even the bug fixes, and since it would not force changes
142 in the storage of fortunes, it is eminently portable. Consider this a
143 'todo' announcement.
144
145 Added (early October 95):
146 A new executable, rot, which is a rot13 filter (a caesar cipher). Most
147 probably have caesar, but on the other hand, if you compile this mess
148 as root, caesar probably isn't in the path.
149
150 A new parameter to fortune, -n, which permits you to specify the length
151 at which to break between long (-l) and short (-s) fortunes.
152
153 fortune -f now shows probabilities.
154
155 A bug: fortune -a nn% filename filename ... now fails without an error
156 message, if the filename named following the percentage exists in both
157 the inoffensive and the offensive directories (that is, if you have two
158 files containing definitions, one called fortunes/definitions and one
159 called fortunes/off/definitions, and call fortune as: fortune -a 10%
160 definitions religion politics ..., then fortune simply fails). This
161 appears to be an artifact of the changes that were made in storage/
162 naming of offensive fortunes. It only happens with the combination of
163 a percentage with -a and inoffensive/offensive files that share a name.
164 Temporary workaround: rename one or the other of the files (*sigh* I
165 don't like that as a solution).
166
167 The man pages have been updated. The old man pages are also available,
168 but are not installed unless you do it yourself (the new ones are). The
169 new man pages have the extension .man; the old ones have numeric
170 extensions.
171
172 A place has been created for fortune files containing HTML tags (the
173 reason I started playing with this mess was because I wanted to be
174 able to format fortunes nicely for the web without having to run an
175 enormously complex script to figure out from formatting how best to
176 display things, a particular problem since the formatting isn't
177 consistent). Tagged fortunes don't exist yet, and I'm seriously
178 considering creating a slightly different fortune binary that would
179 output the necessary headers and trailers (reducing the CGI script
180 to complete triviality) (-f isn't really needed for a webfortune).
181
182 Todo: I'm thinking of adding a -x to unstr, to rot13 the output. This
183 would have the effect of putting all the necessary tools in one package.
184 It further breaks compatibility with BSD tools (which has *mostly* been
185 maintained, merely enhanced slightly, although the change in how
186 offensive files are distinguished from inoffensive might be regarded as
187 breaking compatibility) by adding yet another parameter to unstr, which
188 didn't have any, before. So I haven't decided, yet.
189
190 Todo: KOI8 encoded fortunes? They couldn't be rotated without a great
191 deal of trouble, of course.
192
193 More minor fixes:
194
195 The way that fortune -m prints its output has been slightly changed. It
196 used to print the delimiter first, then, if this were the first fortune
197 from a particular file, it printed the name of the file in parentheses.
198 It now prints the first fortune without an initial delimiter; if the
199 fortune is the first from a particular file, it then prints
200 (filename), newline, delimiter, newline *to stderr*. Redirect stderr to
201 stdout to get something *similar to* (but not the same as) the old
202 behavior. The new behavior, if stderr is redirected to stdout, and
203 both are then redirected to a file, produces fictitious entries, one
204 per file in which a match was found. However, whether stderr is
205 redirected or not, the new format produces files that strfile can
206 parse without choking (the old format, since it placed the filename
207 on the same line as the delimiter character, effectively forced editing
208 of the file in order to make it usable by strfile, unless the option of
209 concatenating two fortunes with an ugly "% (filename)" line separating
210 them was considered acceptable output). Under the new display format,
211 if stderr is redirected into the file, you end up with filenames marking
212 the separation between files (as before), but they are now valid text
213 strings (which should probably, therefore, be deleted).
214
215 In other words, if you don't care what files the original text came from,
216 and want a new file containing (let us say), quotes from Mark Twain,
217 you might do:
218 fortune -am '-- Mark Twain' >twain
219 The files accessed would march down the screen; the fortunes would be
220 stored in parsable format into the file twain. If, however, you planned
221 to edit (perhaps to remove the quotes from the original file, you might
222 then wish to redirect stderr to stdout. Using bash:
223 fortune -am '-- Mark Twain' &>twain
224 or
225 fortune -am '-- Mark Twain' >twain 2>&1
226
227 [The above is now in the man page, more or less]
228
229 Late September, 1995
230 Too many changes to mention, really. Look at the source code for
231 comments on individual files. LINUX.DIF has been removed.
232
233 It is worth noting that strfile was completely broken as distributed,
234 and fortune had code to make it report a different file list than the
235 one it used to retrieve fortunes. There's some rather strong language
236 on the subject in strfile.c; if it offends you, tough.
237
238 Bugs were fixed, and some enhancements were added. Unstr, in
239 particular, has had its command line considerably enhanced. Strfile
240 now *really does* sort, instead of merely setting the 'sorted' flag.
241 Ditto for randomizing.
242
243 Noteworthy: the way to distinguish between offensive and non-offensive
244 files has changed for fortune. A second directory (which may be a
245 subdirectory of the main fortune directory; the program doesn't
246 add files recursively down a directory tree) has been added to
247 pathnames.h. Offensive files should be placed there. There is no
248 longer any need to add the -o suffix to file names, and the problems
249 with finding files (especially offensive ones) seem to have
250 disappeared in the process.
251
252 Currently, I'm working on breaking the fortune files themselves into
253 smaller, more manageable pieces, checking spelling, punctuation, and
254 grammar, and trying to reduce redundancy. The eventual goal, after
255 the files are cleaned up, is another set of files carrying HTML tags,
256 which would then massively simplify a CGI script that calls fortune.
257
258 New Makefiles.
259
260 A 'randstr' (I want to call it 'lottery,' but I won't) utility, which
261 amounts to a poor woman's stripped-down fortune, to illustrate some
262 other possible uses of strfile-type random-access strings files.
263
264 Amy A. Lewis [email protected]
265