Bug 193936

Summary: Description of run_rc_script behavior with .sh scripts rc.subr is incorrect
Product: Documentation Reporter: Enji Cooper <ngie>
Component: Manual PagesAssignee: Enji Cooper <ngie>
Status: Closed FIXED    
Severity: Affects Some People CC: crees, doc
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   
See Also: https://reviews.freebsd.org/D18666

Description Enji Cooper freebsd_committer freebsd_triage 2014-09-26 01:01:51 UTC
8.   Call each script in turn using run_rc_script() (from rc.subr(8)),
          which sets $1 to ``start'', and sources the script in a subshell.
          If the script has a .sh suffix then it is sourced directly into the
          current shell.  Stop processing when the script that is the value of
          the $early_late_divider has been run.

r193118 removed support for .sh scripts, so the sentence referencing them above should be deleted.
Comment 1 Enji Cooper freebsd_committer freebsd_triage 2015-08-05 03:08:20 UTC
This was a doc change, not a code change (I don't have a doc bit).

Looking at run_rc_subr, comment was a bit outdated still, but partly correct. I updated rc.subr to be a bit more correct here: https://svnweb.freebsd.org/base?view=revision&revision=286303

Reassigning back to the doc team as the item that needs to the fixed is the handbook, etc.
Comment 2 Chris Rees freebsd_committer freebsd_triage 2018-12-23 15:42:56 UTC
You don't need a doc bit to update a man page!

I'm pretty sure the .sh files aren't mentioned in the Handbook, and they aren't in the Practical RC Scripting article either, so just the man page needs that bit editing out.
Comment 3 Enji Cooper freebsd_committer freebsd_triage 2018-12-29 20:06:33 UTC
I accidentally forgot that FreeBSD uses `PR:` instead of `Bug:` for bug numbers in commit messages. I committed the change to ^/head in r342597 and will fix the annotation in backport commit messages.
Comment 4 commit-hook freebsd_committer freebsd_triage 2019-02-12 23:37:37 UTC
A commit references this bug:

Author: ngie
Date: Tue Feb 12 23:37:21 UTC 2019
New revision: 344068
URL: https://svnweb.freebsd.org/changeset/base/344068

Log:
  MFC r342598:

  Remove legacy rc.d infrastructure references from rc(8)

  Legacy rc.d scripts (.sh extension) have not been supported since
  r193118. Remove the outdated references to the legacy format, as they
  are no longer valid.

  PR:		193936
  Approved by:	jtl (mentor)
  Differential Revision: https://reviews.freebsd.org/D19157

Changes:
_U  stable/11/
  stable/11/share/man/man8/rc.8