aboutsummaryrefslogtreecommitdiff
path: root/system/etc/pm
diff options
context:
space:
mode:
authorKarel Kočí <cynerd@email.cz>2017-04-03 20:42:16 +0200
committerKarel Kočí <cynerd@email.cz>2017-04-03 20:42:16 +0200
commit81836945a63f726033fb6550755e2c9dbf1a1f83 (patch)
tree4202b3b9fdfaf7013660302750b461c3570e2e81 /system/etc/pm
parent151158101618f9392af1e65c4012c90dda3b437f (diff)
downloadmyconfigs-81836945a63f726033fb6550755e2c9dbf1a1f83.tar.gz
myconfigs-81836945a63f726033fb6550755e2c9dbf1a1f83.tar.bz2
myconfigs-81836945a63f726033fb6550755e2c9dbf1a1f83.zip
Add system_install
Diffstat (limited to 'system/etc/pm')
-rwxr-xr-xsystem/etc/pm/sleep.d/10lock13
1 files changed, 13 insertions, 0 deletions
diff --git a/system/etc/pm/sleep.d/10lock b/system/etc/pm/sleep.d/10lock
new file mode 100755
index 0000000..da7c018
--- /dev/null
+++ b/system/etc/pm/sleep.d/10lock
@@ -0,0 +1,13 @@
+#!/bin/sh
+#
+# 10sleep: lock i3 season before suspend
+
+case "$1" in
+ hibernate|suspend)
+ for socket in `find /run/user/*/i3 -name ipc-socket*`; do
+ i3-msg -s $socket "exec i3lock -d -c 000000"
+ done
+ ;;
+ *) exit $NA
+ ;;
+esac