diff options
author | Jose Luis Duran <jlduran@gmail.com> | 2022-03-13 17:48:06 +0000 |
---|---|---|
committer | Mateusz Piotrowski <0mp@FreeBSD.org> | 2022-03-13 17:57:29 +0000 |
commit | 325ebf37d8efc6488754051fcc2b1aaa40cefd8b (patch) | |
tree | 37a7adafa90b752fc9190ea388e9a8ef6b8016fe /share | |
parent | e83a53abeb90258206285be517af2f2045caa78b (diff) | |
download | src-325ebf37d8efc6488754051fcc2b1aaa40cefd8b.tar.gz src-325ebf37d8efc6488754051fcc2b1aaa40cefd8b.zip |
Introduce startmsg and use it in rc scripts
startmsg is a new rc.subr(8) function function to be used instead of
echo(1) when for boot messages. It replaces the often forgotten
check_startmsgs && echo ...
with
startmsg ...
No functional change intended.
I adjusted the commit message and did some final clean-ups of the patch
before committing.
PR: 255207
Reported by: Jose Luis Duran <jlduran@gmail.com>
Reviewed by: imp, 0mp
Approved by: imp (src)
Differential Revision: https://reviews.freebsd.org/D34514
Diffstat (limited to 'share')
-rw-r--r-- | share/man/man8/rc.subr.8 | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/share/man/man8/rc.subr.8 b/share/man/man8/rc.subr.8 index 14718ecf2737..5a093cb99e8b 100644 --- a/share/man/man8/rc.subr.8 +++ b/share/man/man8/rc.subr.8 @@ -29,7 +29,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 29, 2021 +.Dd March 13, 2022 .Dt RC.SUBR 8 .Os .Sh NAME @@ -73,6 +73,8 @@ .It .Ic run_rc_script Ar file Ar argument .It +.Ic startmsg Oo Fl n Oc Ar message +.It .Ic wait_for_pids Op Ar pid ... .It .Ic warn Ar message @@ -881,6 +883,17 @@ otherwise source .Ar file into the current shell. .El +.It Ic startmsg Oo Fl n Oc Ar message +Display a start message to +.Va stdout . +It should be used instead of +.Xr echo 1 . +The display of this output can be turned off if the +.Xr rc.conf 5 +variable +.Va rc_startmsgs +is set to +.Dq Li NO . .It Ic stop_boot Op Ar always Prevent booting to multiuser mode. If the |