Difference between revisions of "KDE"

1,071 bytes added ,  1 month ago
Add End Session Commands
(Add KCMs)
Tags: Mobile web edit Mobile edit
(Add End Session Commands)
Tags: Mobile web edit Mobile edit
Line 106: Line 106:
</pre>
</pre>
}}
}}
=====End Session Commands=====
Logging out or shutting down via a command can be useful whether for a non-graphical environment or inclusion in scripts. Whenever a plasma session is involved using the following commands should be preferred over more generic options such as ''systemctl reboot''.
======Prompt======
DBUS provides methods to open a prompt to end a session (logout, reboot, shutdown).
{{UserCmd|command=qdbus6 org.kde.LogoutPrompt /LogoutPrompt promptLogout}}
{{UserCmd|command=qdbus6 org.kde.LogoutPrompt /LogoutPrompt promptReboot}}
{{UserCmd|command=qdbus6 org.kde.LogoutPrompt /LogoutPrompt promptShutDown}}
{{UserCmd|command=qdbus6 org.kde.LogoutPrompt /LogoutPrompt promptAll}}
======Immediate======
Similar commands can be used to initiate the process without any prompt.
{{UserCmd|command=qdbus6 org.kde.Shutdown /Shutdown savesession}}
{{UserCmd|command=qdbus6 org.kde.Shutdown /Shutdown logout}}
{{UserCmd|command=qdbus6 org.kde.Shutdown /Shutdown logoutAndReboot}}
{{UserCmd|command=qdbus6 org.kde.Shutdown /Shutdown logoutAndShutdown}}