From: Thierry Parmentelat Date: Tue, 27 Mar 2012 12:51:37 +0000 (+0200) Subject: rename reload from plc.d/functions into plc_reload X-Git-Tag: myplc-5.1-1~5 X-Git-Url: http://git.onelab.eu/?p=myplc.git;a=commitdiff_plain;h=91237815a9777bcbdd1c72a3b870cfaa349bfbca rename reload from plc.d/functions into plc_reload to avoid confusion with builtin /sbin/reload --- diff --git a/plc.d/functions b/plc.d/functions index b5811c7..3ca315b 100644 --- a/plc.d/functions +++ b/plc.d/functions @@ -99,7 +99,7 @@ function upper () { } # Regenerate configuration files -function reload () { +function plc_reload () { force=$1 # Regenerate the main configuration file from default values diff --git a/plc.init b/plc.init index c98b0c1..c3ae8f4 100755 --- a/plc.init +++ b/plc.init @@ -8,6 +8,7 @@ # # Source function library and configuration +# plc_reload is defined here . /etc/plc.d/functions # Verbosity @@ -100,7 +101,7 @@ command=$1 shift 1 if [ -z "$1" ] ; then # Start or stop everything. Regenerate configuration first. - reload force + plc_reload force else # Start or stop a particular step steps=("$@") @@ -115,7 +116,7 @@ start () if [ -x /etc/plc.d/$step ] ; then /etc/plc.d/$step start # Steps may alter the configuration, may need to regenerate - reload + plc_reload else echo "PLC: $step: unrecognized step" >&4 exit 1 @@ -130,7 +131,7 @@ stop () if [ -x /etc/plc.d/$step ] ; then /etc/plc.d/$step stop # Steps may alter the configuration, may need to regenerate - reload + plc_reload else echo "PLC: $step: unrecognized step" >&4 exit 1 @@ -149,7 +150,7 @@ case "$command" in ;; reload) - reload force + plc_reload force ;; checkpoint)