summaryrefslogtreecommitdiff
path: root/etc
diff options
context:
space:
mode:
authorjmmv <jmmv@NetBSD.org>2004-04-02 13:13:47 +0000
committerjmmv <jmmv@NetBSD.org>2004-04-02 13:13:47 +0000
commit3c8a1444d9a85ddcdc7a981606f30ca6dc22dfd6 (patch)
tree8474973e74a5457c6d26fe5af2cfbd46d9a32d57 /etc
parent37135b824ffbc56167175c91f14ffb1ba543f383 (diff)
Introduce and use the rcvar_manpage variable, which contains the manual page
name where the user should look at for documentation about rcvar. It defaults to 'rc.subr(5)', as rc.subr is mainly used by rc.d scripts. This variable is useful to let the daily, weekly, monthly and security scripts tune the warning message shown when any of the variables they handle is not properly set. Closes PR misc/23908.
Diffstat (limited to 'etc')
-rw-r--r--etc/daily3
-rw-r--r--etc/monthly3
-rw-r--r--etc/rc.subr6
-rw-r--r--etc/security4
-rw-r--r--etc/weekly3
5 files changed, 13 insertions, 6 deletions
diff --git a/etc/daily b/etc/daily
index 65e5c0fe625..cc20848d1ae 100644
--- a/etc/daily
+++ b/etc/daily
@@ -1,6 +1,6 @@
#!/bin/sh -
#
-# $NetBSD: daily,v 1.58 2004/03/29 02:17:26 mrg Exp $
+# $NetBSD: daily,v 1.59 2004/04/02 13:13:47 jmmv Exp $
# @(#)daily 8.2 (Berkeley) 1/25/94
#
@@ -13,6 +13,7 @@ fi
host=`hostname`
date=`date`
+rcvar_manpage='daily.conf(5)'
echo "To: ${MAILTO:-root}"
echo "Subject: $host daily output for $date"
diff --git a/etc/monthly b/etc/monthly
index 558618ad74c..fdad2af0440 100644
--- a/etc/monthly
+++ b/etc/monthly
@@ -1,6 +1,6 @@
#!/bin/sh -
#
-# $NetBSD: monthly,v 1.8 2000/01/10 17:03:49 ad Exp $
+# $NetBSD: monthly,v 1.9 2004/04/02 13:13:47 jmmv Exp $
# from: @(#)monthly 8.1 (Berkeley) 6/9/93
#
@@ -13,6 +13,7 @@ fi
host=`hostname`
date=`date`
+rcvar_manpage='monthly.conf(5)'
echo "To: ${MAILTO:-root}"
echo "Subject: $host monthly output for $date"
diff --git a/etc/rc.subr b/etc/rc.subr
index e9872d6c7a7..67d7fc1ed22 100644
--- a/etc/rc.subr
+++ b/etc/rc.subr
@@ -1,4 +1,4 @@
-# $NetBSD: rc.subr,v 1.61 2004/01/06 00:52:24 lukem Exp $
+# $NetBSD: rc.subr,v 1.62 2004/04/02 13:13:47 jmmv Exp $
#
# Copyright (c) 1997-2002 The NetBSD Foundation, Inc.
# All rights reserved.
@@ -38,6 +38,8 @@
# functions used by various rc scripts
#
+: ${rcvar_manpage:='rc.conf(5)'}
+
#
# functions
# ---------
@@ -62,7 +64,7 @@ checkyesno()
return 1
;;
*)
- warn "\$${1} is not set properly - see rc.conf(5)."
+ warn "\$${1} is not set properly - see ${rcvar_manpage}."
return 1
;;
esac
diff --git a/etc/security b/etc/security
index 3b2853c486d..b218953e06b 100644
--- a/etc/security
+++ b/etc/security
@@ -1,11 +1,13 @@
#!/bin/sh -
#
-# $NetBSD: security,v 1.88 2004/02/09 09:04:13 jdolecek Exp $
+# $NetBSD: security,v 1.89 2004/04/02 13:13:47 jmmv Exp $
# from: @(#)security 8.1 (Berkeley) 6/9/93
#
PATH=/sbin:/usr/sbin:/bin:/usr/bin
+rcvar_manpage='security.conf(5)'
+
if [ -f /etc/rc.subr ]; then
. /etc/rc.subr
else
diff --git a/etc/weekly b/etc/weekly
index 7a22217015c..2cc622f144d 100644
--- a/etc/weekly
+++ b/etc/weekly
@@ -1,6 +1,6 @@
#!/bin/sh -
#
-# $NetBSD: weekly,v 1.17 2001/06/18 10:54:02 lukem Exp $
+# $NetBSD: weekly,v 1.18 2004/04/02 13:13:47 jmmv Exp $
# from: @(#)weekly 8.2 (Berkeley) 1/2/94
#
@@ -13,6 +13,7 @@ fi
host=`hostname`
date=`date`
+rcvar_manpage='weekly.conf(5)'
echo "To: ${MAILTO:-root}"
echo "Subject: $host weekly output for $date"