diff options
author | Tom Willemsen | 2011-10-17 00:07:14 +0200 |
---|---|---|
committer | Tom Willemsen | 2011-10-17 00:07:14 +0200 |
commit | 9e4506a7d2fc2dd0bae551ed2dd73794111ca957 (patch) | |
tree | c7196d21cd45427a96eb6d13e08401e0a9945861 | |
parent | 2bd25352862d1c6291fac4fd00d608df1a764385 (diff) | |
download | dotfiles-9e4506a7d2fc2dd0bae551ed2dd73794111ca957.tar.gz dotfiles-9e4506a7d2fc2dd0bae551ed2dd73794111ca957.zip |
ZSH: Add user shutdown functions
These functions overwrite the executables reboot and shutdown
-rw-r--r-- | .zshrc | 16 |
1 files changed, 16 insertions, 0 deletions
@@ -32,6 +32,22 @@ function line() echo " $1" } +function shutdown() +{ + dbus-send --system --print-reply \ + --dest="org.freedesktop.ConsoleKit" \ + /org/freedesktop/ConsoleKit/Manager \ + org.freedesktop.ConsoleKit.Manager.Stop +} + +function reboot() +{ + dbus-send --system --print-reply \ + --dest="org.freedesktop.ConsoleKit" \ + /org/freedesktop/ConsoleKit/Manager \ + org.freedesktop.ConsoleKit.Manager.Restart +} + # Initialize colors. autoload -U colors colors |