From: Mark Wooding Date: Wed, 23 Sep 2009 12:02:54 +0000 (+0100) Subject: Merge branch 'master' of git+ssh://ponder.ncipher.com/~mwooding/etc/profile X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~mdw/git/profile/commitdiff_plain/918e99b0cfe5655bae0f4fea77838b3f857712e7?hp=a5abc1d29be727b2eb2159a614c9f12b5e2ea9d9 Merge branch 'master' of git+ssh://ponder.ncipher.com/~mwooding/etc/profile * 'master' of git+ssh://ponder.ncipher.com/~mwooding/etc/profile: dot/bash_profile: Make OpenOffice not use ugly widgets. dot/gnus.el: Use distinct article buffers for different groups. dot/emacs, el/dot-emacs.el: Reformat in line with current styles. --- diff --git a/bin/lock-screen b/bin/lock-screen new file mode 100755 index 0000000..5401260 --- /dev/null +++ b/bin/lock-screen @@ -0,0 +1,25 @@ +#! /bin/sh + +set -e + +win=no + +## xscreensaver +if xscreensaver-command -version >/dev/null 2>&1; then + xscreensaver-command -lock + win=yes +fi + +## gnome-screensaver +if gnome-screensaver-command --query >/dev/null 2>&1; then + gnome-screensaver-command --lock + win=yes +fi + +## Make sure we did something useful. +case $win in + no) + echo >&2 "$0: no screensaver found" + exit 1 + ;; +esac diff --git a/dot/e16-bindings b/dot/e16-bindings index 8cf502c..2875ee7 100644 --- a/dot/e16-bindings +++ b/dot/e16-bindings @@ -28,11 +28,12 @@ Tooltip Go Back a Desktop MouseDown * 5 desk next Tooltip Go Forward a Desktop Aclass KEYBINDINGS global +KeyDown 5 F6 exec gconftool --toggle /desktop/gnome/accessibility/keyboard/mousekeys_enable KeyDown 5 F7 exec un-backslashify-selection KeyDown 5 F8 exec xatom set XINIT_COMMAND :terminal KeyDown 5 F9 exec xatom set XINIT_COMMAND :ask-run KeyDown 5 F10 exec xatom set XINIT_COMMAND :ask-command -KeyDown 5 F11 exec gnome-screensaver-command --lock +KeyDown 5 F11 exec lock-screen KeyDown 5 F12 exec xshutdown KeyDown 5 Tab focus next KeyDown 5 plus desk next diff --git a/dot/xinitrc b/dot/xinitrc index 7543e15..a0722c5 100755 --- a/dot/xinitrc +++ b/dot/xinitrc @@ -125,6 +125,14 @@ start-clients () { ## System monitor. case $vnc in no) run bginit gkrellm ;; esac + ## Screensaver. + case $vnc in + no) + run init xscreensaver-command -exit + run bginit xscreensaver -no-splash + ;; + esac + ## Panel. case $vnc in no) run bginit gnome-panel ;; esac diff --git a/setup b/setup index 7174162..85c615a 100755 --- a/setup +++ b/setup @@ -220,6 +220,7 @@ scripts=" [ "$xstuff" ] && scripts="$scripts xinitcmd un-backslashify-selection + lock-screen xshutdown" echo "Installing scripts..." mkdir -p $HOME$sub/bin