mirror of
https://github.com/rbreaves/kinto.git
synced 2025-08-14 22:59:14 +02:00
- WIP adding proper closing of xkeysnail on logoff
This commit is contained in:
6
xkeysnail-config/logoff.sh
Executable file
6
xkeysnail-config/logoff.sh
Executable file
@@ -0,0 +1,6 @@
|
||||
dbus-monitor --session "type='signal',interface='org.gnome.SessionManager.Logout'" | grep '1' |
|
||||
while read x; do
|
||||
echo "$x"
|
||||
sudo systemctl stop xkeysnail
|
||||
break
|
||||
done
|
@@ -2,7 +2,7 @@
|
||||
Name=Kinto_xkey
|
||||
GenericName=Kinto_xkey
|
||||
Comment=Make Linux Type Like it's a Mac
|
||||
Exec=/bin/bash -c "{xhost} +SI:localuser:root && sudo {systemctl} restart xkeysnail"
|
||||
Exec=/bin/bash -c "{xhost} +SI:localuser:root && sudo {systemctl} restart xkeysnail && {homedir}/.config/kinto/logoff.sh"
|
||||
Terminal=false
|
||||
Type=Application
|
||||
X-GNOME-Autostart-enabled=true
|
@@ -4,9 +4,8 @@ Description=xkeysnail
|
||||
[Service]
|
||||
Type=simple
|
||||
KillMode=process
|
||||
ExecStartPre=/bin/bash -c "{xhost} +SI:localuser:root && /sbin/runuser -l {username} -c {homedir}/.config/kinto/prexk.sh"
|
||||
ExecStart=/usr/bin/sudo /bin/bash -c '{experimental-caret}{homedir}/.config/kinto/xkeystart.sh /tmp/kinto/xkeysnail/kinto.py'
|
||||
ExecStop=/bin/bash -c 'me=$$;ps -ef | grep \'[t]mp/kinto\' | awk -v me=$me \'$2 != me {print $2}\' | xargs kill;/usr/bin/killall dbus-monitor;/usr/bin/killall xkeysnail;{kill-caret}'
|
||||
ExecStart=/usr/bin/sudo /bin/bash -c '/usr/bin/xhost +SI:localuser:root && /usr/local/bin/xkeysnail --quiet --watch {homedir}/.config/kinto/kinto.py'
|
||||
ExecStop=/usr/bin/killall xkeysnail
|
||||
Restart=on-failure
|
||||
RestartSec=3
|
||||
Environment=DISPLAY={displayid}
|
||||
|
Reference in New Issue
Block a user