From e2707f4d9fe6f792427fb08cfdc58354f29de5b0 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Fri, 16 Oct 2009 12:51:21 +0200 Subject: off: Remove [place] argument, I don't use it anyway --- etc/functions/off | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) (limited to 'etc/functions') diff --git a/etc/functions/off b/etc/functions/off index 12997f4..53f9343 100644 --- a/etc/functions/off +++ b/etc/functions/off @@ -9,7 +9,6 @@ typeset filesystem garbage file typeset -a filesystems typeset tune2fs typeset -i force reboot simulate exit_ok=1 -typeset gone function execute { if (( simulate )) { @@ -26,15 +25,12 @@ while [[ $1 == -* ]] { --force) force=1 ;; -h) print 'off - shutdown / restart the system' - print 'Usage: off [--force] [-hnr] [place]' + print 'Usage: off [--force] [-hnr]' print 'Options:\n' print ' -n simulate. Do not actually shutdown' print ' -r reboot' print ' -h show this message' print '\--force shutdown even if the machine is a server' - print '' - print ' place supply if machine will remain off for some time,' - print ' either "gone" or the place one will be going to' return 0 ;; -|--) shift; break ;; @@ -43,8 +39,6 @@ while [[ $1 == -* ]] { shift } -gone=$1 - # Don't shut down a server too easily if [[ $force != 1 && $hosts[$HOST] == *:server:* ]] { warn "This seems to be a server... not shutting down" @@ -52,16 +46,6 @@ if [[ $force != 1 && $hosts[$HOST] == *:server:* ]] { return 1 } -if [[ -n $gone ]] { - for file in ~/packages/leave.d/etc/{_any,$gone}/*(N); { - if [[ ${file:e} == zsh ]] { - execute source $file - } else { - execute $file - } - } -} - if pgrep -x amarokapp &> /dev/null; then execute dcop amarok MainApplication-Interface quit fi -- cgit v1.2.3