Page MenuHomeFreeBSD

Remove fortune(6)

Authored by cy on Nov 26 2017, 6:49 AM.


Group Reviewers

Fortune(6)'s time has come to live in ports. games/bsdgames already has fortune in its tarball (and can be installed if the maintainer of the port wishes to exercise it). This patch removes fortune.

Test Plan

tinderbox build.

Diff Detail

rS FreeBSD src repository
Lint Skipped
Unit Tests Skipped
Build Status
Buildable 13067

Event Timeline

cy created this revision.Nov 26 2017, 6:49 AM
cy added a comment.Nov 26 2017, 7:24 AM

Who else should review/approve this?

adrian accepted this revision.Nov 26 2017, 7:24 AM


This revision is now accepted and ready to land.Nov 26 2017, 7:24 AM
jilles requested changes to this revision.Nov 26 2017, 1:25 PM
jilles added a subscriber: jilles.

This will leave the calls to /usr/bin/fortune in share/skel/dot.login and share/skel/dot.profile referring to something that does not and will not exist (the port will install as /usr/local/bin/fortune).

Also, there doesn't appear to be consensus in the mailing list threads that freebsd-tips should also be removed.

This revision now requires changes to proceed.Nov 26 2017, 1:25 PM
ian requested changes to this revision.Nov 26 2017, 5:09 PM

People have existing references/calls to fortune in their shell startup scripts. Removing the program could potentially leave people unable to login remotely in a worst case. I don't believe removing the binary is a viable option.

If the binary must be moved to ports, then it also must be replaced with a mechanism similar to how pkg(8) bootstraps itself. For example, fortune could become a shell script that execs /usr/local/bin/fortune if it exists, or emits a message telling users the name of the package to install to restore full functionality.

Replacing it with a placeholder bootstrap fortune shell script to retain backward compat is a smart move.

cy added a comment.Nov 26 2017, 6:11 PM

Replacing the binary with a shell script that conditionally executes ${LOCALBASE}/bin/fortune (if there) makes a lot of sense. IMO the script should advise the user to install the package or request the package from their sysadmin.

I'll update the diff after the Grey Cup today. The port will take a little more time to cobble from bsdgames.

P.S. I totally willing to let someone else take the lead on this if they want.

cy abandoned this revision.Nov 27 2017, 5:34 AM

It appears the decision has already been made.