Move lock.sh and LockScreen.png into config folder

This commit is contained in:
Adam Goldsmith 2017-10-31 03:55:25 -04:00
parent adc85b5db7
commit bb81c09ed9
3 changed files with 41 additions and 5 deletions

BIN
.config/i3/LockScreen.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

View File

@ -10,7 +10,6 @@ exec --no-startup-id redshift-gtk -l 43:-72
exec --no-startup-id insync start exec --no-startup-id insync start
exec --no-startup-id syncthing-gtk exec --no-startup-id syncthing-gtk
exec --no-startup-id start-pulseaudio-x11 && sleep 10 && volumeicon exec --no-startup-id start-pulseaudio-x11 && sleep 10 && volumeicon
exec --no-startup-id xss-lock -l /home/adam/.bin/i3lock-wrapper.sh
exec --no-startup-id udiskie -s0 exec --no-startup-id udiskie -s0
exec --no-startup-id caffeine exec --no-startup-id caffeine
exec --no-startup-id thunderbird exec --no-startup-id thunderbird
@ -32,9 +31,9 @@ bindsym $mod+Return exec roxterm # start a termin
bindsym $mod+e exec emacsclient -c -n # start emacs bindsym $mod+e exec emacsclient -c -n # start emacs
bindsym $mod+Shift+e exec thunderbird # start thunderbird bindsym $mod+Shift+e exec thunderbird # start thunderbird
bindsym Mod1+Mod4+s exec /home/adam/.bin/lock.sh suspend # suspend bindsym Mod1+Mod4+s exec $config_dir/lock.sh suspend # suspend
bindsym Mod1+Control+l exec /home/adam/.bin/lock.sh lock # lock screen bindsym Mod1+Control+l exec $config_dir/lock.sh lock # lock screen
bindsym Mod1+Control+Delete exec /home/adam/.bin/lock.sh pick # power menu bindsym Mod1+Control+Delete exec $config_dir/lock.sh pick # power menu
bindsym $mod+p exec --no-startup-id ~/.bin/killPanel.sh # restart xfce4-panel bindsym $mod+p exec --no-startup-id ~/.bin/killPanel.sh # restart xfce4-panel
mode "launch" { mode "launch" {

37
.config/i3/lock.sh Executable file
View File

@ -0,0 +1,37 @@
#!/bin/bash
lock() {
killall -SIGHUP gpg-agent
setxkbmap -option 'ctrl:nocaps' -option "shift:both_capslock"
i3lock -i /home/adam/.config/i3/LockScreen.png -ec222222
}
case "$1" in
lock)
lock
;;
logout)
i3-msg exit
;;
suspend)
lock && systemctl suspend
;;
hibernate)
lock && systemctl hibernate
;;
reboot)
systemctl reboot
;;
shutdown)
systemctl poweroff
;;
pick)
$0 $(echo -e "lock\nlogout\nsuspend\nhibernate\nreboot\nshutdown" | rofi -dmenu -i -bg '#222222' -fg '#cccccc' -fg-active '#ffffff')
;;
*)
echo "Usage: $0 {lock|logout|suspend|hibernate|reboot|shutdown|pick}"
exit 2
;;
esac
exit 0