diff options
author | dougb <dougb@FreeBSD.org> | 2012-01-14 16:57:23 +0800 |
---|---|---|
committer | dougb <dougb@FreeBSD.org> | 2012-01-14 16:57:23 +0800 |
commit | 4500e6f95eef76996051b447f00584b31e4abedf (patch) | |
tree | aa85e69ac86658b87b78e09ff440d65dc0ff7518 /news | |
parent | 9b5808c5a6c860e753267e93e9516b3301002f03 (diff) | |
download | freebsd-ports-gnome-4500e6f95eef76996051b447f00584b31e4abedf.tar.gz freebsd-ports-gnome-4500e6f95eef76996051b447f00584b31e4abedf.tar.zst freebsd-ports-gnome-4500e6f95eef76996051b447f00584b31e4abedf.zip |
In the rc.d scripts, change assignments to rcvar to use the
literal name_enable wherever possible, and ${name}_enable
when it's not, to prepare for the demise of set_rcvar().
In cases where I had to hand-edit unusual instances also
modify formatting slightly to be more uniform (and in
some cases, correct). This includes adding some $FreeBSD$
tags, and most importantly moving rcvar= to right after
name= so it's clear that one is derived from the other.
Diffstat (limited to 'news')
-rw-r--r-- | news/inn/files/innd.sh.in | 13 | ||||
-rw-r--r-- | news/newscache/files/newscache.sh.in | 2 | ||||
-rw-r--r-- | news/nntpcache/files/nntpcached.in | 2 | ||||
-rw-r--r-- | news/sabnzbdplus/files/sabnzbd.in | 2 |
4 files changed, 7 insertions, 12 deletions
diff --git a/news/inn/files/innd.sh.in b/news/inn/files/innd.sh.in index ef7b056ba982..a86073304c93 100644 --- a/news/inn/files/innd.sh.in +++ b/news/inn/files/innd.sh.in @@ -1,17 +1,17 @@ #!/bin/sh + +# $FreeBSD$ # # PROVIDE: innd # REQUIRE: DAEMON # KEYWORD: shutdown -# -# $FreeBSD$ -# . /etc/rc.subr name=innd +rcvar=innd_enable -PREFIX=%%PREFIX%% +load_rc_config ${name} innd_enable=${innd_enable-"NO"} innd_user=${innd_user-"news"} @@ -19,13 +19,9 @@ innd_group=${innd_group-"news"} required_files="%%DBDIR%%/history.dir" -load_rc_config ${name} - start_cmd=${name}_start stop_cmd=${name}_stop -rcvar=`set_rcvar` - command=%%NEWSBASE%%/bin/rc.news innd_start() { @@ -36,5 +32,4 @@ innd_stop() { su -fm ${innd_user} -c "${command} stop" } -load_rc_config ${name} run_rc_command "$1" diff --git a/news/newscache/files/newscache.sh.in b/news/newscache/files/newscache.sh.in index c31162d85a8c..57830d8ad51d 100644 --- a/news/newscache/files/newscache.sh.in +++ b/news/newscache/files/newscache.sh.in @@ -15,7 +15,7 @@ newscache_enable=${newscache_enable-"NO"} . /etc/rc.subr name=newscache -rcvar=`set_rcvar` +rcvar=newscache_enable command=%%PREFIX%%/sbin/${name} pidfile=/var/run/${name}.pid diff --git a/news/nntpcache/files/nntpcached.in b/news/nntpcache/files/nntpcached.in index 42bb50cac535..dbec9bc1ff87 100644 --- a/news/nntpcache/files/nntpcached.in +++ b/news/nntpcache/files/nntpcached.in @@ -13,7 +13,7 @@ . /etc/rc.subr name=nntpcached -rcvar=`set_rcvar` +rcvar=nntpcached_enable load_rc_config $name diff --git a/news/sabnzbdplus/files/sabnzbd.in b/news/sabnzbdplus/files/sabnzbd.in index 98e37318111e..5e8a4016233b 100644 --- a/news/sabnzbdplus/files/sabnzbd.in +++ b/news/sabnzbdplus/files/sabnzbd.in @@ -23,7 +23,7 @@ . /etc/rc.subr name="sabnzbd" -rcvar=${name}_enable +rcvar=sabnzbd_enable load_rc_config ${name} |