https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=246735

            Bug ID: 246735
           Summary: [PATCH] Do not restrict fortune(6) to only searching
                    for files named "fortunes" by default
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: bin
          Assignee: b...@freebsd.org
          Reporter: nipkr...@gmail.com

Created attachment 214860
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=214860&action=edit
Patch to allow fortune(6) to look for all fortune files in the fortune
directory

Currently, fortune(6) by default looks in the fortune directory for a data file
named "fortunes", and if none are found, displays "No fortunes found". Any
fortune file must be explicitly specified; ex. to display a fortune from the
file "freebsd-tips" one must use the command "fortune freebsd-tips".
Previously, this behaviour would be acceptable, as a "fortunes" data file used
to be packaged with the base system, but as of base r325828, FreeBSD does not
distribute such a data file. This may be unexpected to users who expect
"fortune" to generate a fortune from "freebsd-tips", which is distributed with
the base system.

This patch removes this restriction on fortune(6). The new default behaviour
would be to look for any file within the default fortunes directory, regardless
of name. By default, this will result in fortune(6) yielding fortunes from
freebsd-tips, with fortunes being yielded from various sources as more are
installed (either locally or via ports/pkg). This behaviour may be somewhat
unexpected to users who are used to the old behaviour of fortune(6), but is not
likely to cause breaking issues. Users who wish to return to the old behaviour
will be able to use the command "fortune fortunes" to replicate it.

This patch fixes bug #237768 and was originally posted on that bug's thread by
me two months ago. I am terribly sorry if this isn't the correct procedure for
submitting a patch to a preexisting bug; I'm new to contributing to FreeBSD and
I'm not entirely certain if the wording found in the "Contributing to FreeBSD"
handbook suggests that a new bug report should be opened for patches which fix
bugs which already have reports filed.

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
freebsd-bugs@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-bugs
To unsubscribe, send any mail to "freebsd-bugs-unsubscr...@freebsd.org"

Reply via email to