summaryrefslogtreecommitdiff
path: root/templates/system
diff options
context:
space:
mode:
authorhydrajump <wave@hydrajump.com>2014-04-10 14:05:21 +0200
committerhydrajump <wave@hydrajump.com>2014-04-10 14:05:21 +0200
commitcbfe963979e95829365d2d18c3cd2218109ee707 (patch)
tree306a359fd77e379d81364322e29a45ac70f99e2d /templates/system
parent332f9266b2b09e7afec24a31075f8552a6765564 (diff)
downloadvyatta-cfg-system-cbfe963979e95829365d2d18c3cd2218109ee707.tar.gz
vyatta-cfg-system-cbfe963979e95829365d2d18c3cd2218109ee707.zip
Use elif conditional instead of if
Diffstat (limited to 'templates/system')
-rw-r--r--templates/system/options/ctrl-alt-del-action/node.def8
1 files changed, 2 insertions, 6 deletions
diff --git a/templates/system/options/ctrl-alt-del-action/node.def b/templates/system/options/ctrl-alt-del-action/node.def
index d13fe3c5..8ee98ce8 100644
--- a/templates/system/options/ctrl-alt-del-action/node.def
+++ b/templates/system/options/ctrl-alt-del-action/node.def
@@ -12,14 +12,10 @@ end:
if [ $VAR(@) == "disable" ]; then
sudo sh -c "sed -i -e 's/^ca.*/ca:12345:ctrlaltdel:/' \
/etc/inittab"
- fi
-
- if [ $VAR(@) == "reboot" ]; then
+ elif [ $VAR(@) == "reboot" ]; then
sudo sh -c "sed -i -e 's/^ca.*/ca:12345:ctrlaltdel:\/sbin\/reboot/' \
/etc/inittab"
- fi
-
- if [ $VAR(@) == "poweroff" ]; then
+ elif [ $VAR(@) == "poweroff" ]; then
sudo sh -c "sed -i -e 's/^ca.*/ca:12345:ctrlaltdel:\/sbin\/shutdown -h now/' \
/etc/inittab"
fi