forked from Shinonome/dots-hyprland
make logout sddm-compatible
This commit is contained in:
@@ -53,7 +53,7 @@ export function launchCustomCommand(command) {
|
|||||||
execAsync([`bash`, `-c`, `systemctl suspend`]).catch(print);
|
execAsync([`bash`, `-c`, `systemctl suspend`]).catch(print);
|
||||||
}
|
}
|
||||||
else if (args[0] == '>logout') { // Log out
|
else if (args[0] == '>logout') { // Log out
|
||||||
execAsync([`bash`, `-c`, `loginctl terminate-user $USER`]).catch(print);
|
execAsync([`bash`, `-c`, `killall Hyprland`]).catch(print);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ export default () => {
|
|||||||
// lock, logout, sleep
|
// lock, logout, sleep
|
||||||
// const lockButton = SessionButton('Lock', 'lock', () => { App.closeWindow('session'); execAsync('gtklock') });
|
// const lockButton = SessionButton('Lock', 'lock', () => { App.closeWindow('session'); execAsync('gtklock') });
|
||||||
const lockButton = SessionButton('Lock', 'lock', () => { App.closeWindow('session'); execAsync('swaylock') });
|
const lockButton = SessionButton('Lock', 'lock', () => { App.closeWindow('session'); execAsync('swaylock') });
|
||||||
const logoutButton = SessionButton('Logout', 'logout', () => { App.closeWindow('session'); execAsync(['bash', '-c', 'loginctl terminate-user $USER']) });
|
const logoutButton = SessionButton('Logout', 'logout', () => { App.closeWindow('session'); execAsync(['bash', '-c', 'killall Hyprland']) });
|
||||||
const sleepButton = SessionButton('Sleep', 'sleep', () => { App.closeWindow('session'); execAsync('systemctl suspend') });
|
const sleepButton = SessionButton('Sleep', 'sleep', () => { App.closeWindow('session'); execAsync('systemctl suspend') });
|
||||||
// hibernate, shutdown, reboot
|
// hibernate, shutdown, reboot
|
||||||
const hibernateButton = SessionButton('Hibernate', 'downloading', () => { App.closeWindow('session'); execAsync('systemctl hibernate') });
|
const hibernateButton = SessionButton('Hibernate', 'downloading', () => { App.closeWindow('session'); execAsync('systemctl hibernate') });
|
||||||
|
|||||||
@@ -12,7 +12,7 @@
|
|||||||
}
|
}
|
||||||
{
|
{
|
||||||
"label" : "logout",
|
"label" : "logout",
|
||||||
"action" : "loginctl terminate-user $USER",
|
"action" : "killall Hyprland",
|
||||||
"text" : "logout",
|
"text" : "logout",
|
||||||
"keybind" : "e"
|
"keybind" : "e"
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user