Shutting down with keybindings
Posted: Sat Apr 09, 2011 4:44 pm
Hi, I was wondering if anyone could help, I'm trying to shutdown/poweroff with keybindings. I've edited the /etc/sudoers file and put the shortcut in my keys file but all to no avail. What am I doing wrong ? I got the rest of the keys working working no problem. Heres my keys file if anyone finds it useful - the only shortcut that doesn't work is the "halt" one.
OnDesktop Mouse2 :WorkspaceMenu
OnDesktop Mouse3 :RootMenu
KP_Add :NextWorkspace
KP_Subtract :PrevWorkspace
Control m :RootMenu
Alt m :HideMenus
KP_Insert :Maximize
KP_Delete :Minimize
KP_Enter :Fullscreen
Control k :KillWindow
Control c :Close
Control q :Exit
Control z :Exec sudo halt
Control e :ExecCommand eject
Control h :Exec thunar # Ctrl+h will bring up file manager
Control r :ExecCommand rhythmbox # Ctrl+r will bring up music player
Control b :ExecCommand deluge # Ctrl+b will bring up deluge
Control a :ExecCommand abiword # Ctrl+a will bring up abiword
Control f :ExecCommand firefox # Ctrl+f will bring up firefox
Control o :ExecCommand opera # Ctrl+o will bring up opera
Control t :ExecCommand lxterminal # Ctrl+t will bring up an lxterminal
Control l :ExecCommand leafpad # Ctrl+l will bring up leafpad
Control x :ExecCommand xfburn # Ctrl+x will bring up xfburn
Control p :ExecCommand picasa # Ctrl+p will bring up picasa
None Control Right :MoveRight 30
None Control Left :MoveLeft 30
None Control Up :MoveUp 30
None Control Down :MoveDown 30
None Alt Right :ResizeHorizontal 25
None Alt Left :ResizeHorizontal -25
None Alt Up :ResizeVertical -25
None Alt Down :ResizeVertical 25
KP_Prior :MoveTo 0 0 UpperRight -> snap to upper right workspace corner
KP_Home :MoveTo 0 0 UpperLeft -> snap to upper left workspace corner
KP_End :MoveTo 0 0 BottomLeft -> snap to bottom left workspace corner
KP_Next :MoveTo 0 0 BottomRight -> snap to bottom right workspace corner
KP_Begin :MoveTo 0 0 Center -> snap to center of workspace
KP_Right :MoveTo 0 0 RightCenter -> snap to right center of workspace
KP_Left :MoveTo 0 0 LeftCenter -> snap to left center of workspace
KP_8 :MoveTo 0 0 TopCenter -> snap to top center of workspace
KP_Down :MoveTo 0 0 BottomCenter -> snap to bottom center of workspace
#Volume. Will lower or raise volume by 5%. The third key binding will toggle mute.
None XF86AudioRaiseVolume :Exec amixer sset Master,0 5%+
None XF86AudioLowerVolume :Exec amixer sset Master,0 5%-
None XF86AudioMute :Exec amixer sset Master,0 toggle
Thanks
Tony
OnDesktop Mouse2 :WorkspaceMenu
OnDesktop Mouse3 :RootMenu
KP_Add :NextWorkspace
KP_Subtract :PrevWorkspace
Control m :RootMenu
Alt m :HideMenus
KP_Insert :Maximize
KP_Delete :Minimize
KP_Enter :Fullscreen
Control k :KillWindow
Control c :Close
Control q :Exit
Control z :Exec sudo halt
Control e :ExecCommand eject
Control h :Exec thunar # Ctrl+h will bring up file manager
Control r :ExecCommand rhythmbox # Ctrl+r will bring up music player
Control b :ExecCommand deluge # Ctrl+b will bring up deluge
Control a :ExecCommand abiword # Ctrl+a will bring up abiword
Control f :ExecCommand firefox # Ctrl+f will bring up firefox
Control o :ExecCommand opera # Ctrl+o will bring up opera
Control t :ExecCommand lxterminal # Ctrl+t will bring up an lxterminal
Control l :ExecCommand leafpad # Ctrl+l will bring up leafpad
Control x :ExecCommand xfburn # Ctrl+x will bring up xfburn
Control p :ExecCommand picasa # Ctrl+p will bring up picasa
None Control Right :MoveRight 30
None Control Left :MoveLeft 30
None Control Up :MoveUp 30
None Control Down :MoveDown 30
None Alt Right :ResizeHorizontal 25
None Alt Left :ResizeHorizontal -25
None Alt Up :ResizeVertical -25
None Alt Down :ResizeVertical 25
KP_Prior :MoveTo 0 0 UpperRight -> snap to upper right workspace corner
KP_Home :MoveTo 0 0 UpperLeft -> snap to upper left workspace corner
KP_End :MoveTo 0 0 BottomLeft -> snap to bottom left workspace corner
KP_Next :MoveTo 0 0 BottomRight -> snap to bottom right workspace corner
KP_Begin :MoveTo 0 0 Center -> snap to center of workspace
KP_Right :MoveTo 0 0 RightCenter -> snap to right center of workspace
KP_Left :MoveTo 0 0 LeftCenter -> snap to left center of workspace
KP_8 :MoveTo 0 0 TopCenter -> snap to top center of workspace
KP_Down :MoveTo 0 0 BottomCenter -> snap to bottom center of workspace
#Volume. Will lower or raise volume by 5%. The third key binding will toggle mute.
None XF86AudioRaiseVolume :Exec amixer sset Master,0 5%+
None XF86AudioLowerVolume :Exec amixer sset Master,0 5%-
None XF86AudioMute :Exec amixer sset Master,0 toggle
Thanks
Tony