1

I want to know what exact code or command is run when one chooses one of the power options through the start menu in Kubuntu.

I know about the proper ways to shutdown or restart through terminal. That is not what I am asking here.

I notice that when I restart, all my apps will reopen and I find that very useful. So I want to know what magic happens behind the curtain when I restart through the start menu.

EDIT: I am not asking how to do it through gui but what is the equivalent of doing the same thing through terminal. I am also interested in the code the power menu options run in the case of fresh start, aka no save session, as I intend to make each of them into an alias.

screenshot of Kubuntu start menu power options

Usermaxn
  • 197
  • 6
  • 1
    You probably have this feature enabled in `System Settings`>`Startup and Shutdown`>`Desktop Session`. – mook765 May 31 '23 at 21:41
  • Does this answer your question? [Save session settings in KDE environment without shutting down](https://askubuntu.com/questions/633318/save-session-settings-in-kde-environment-without-shutting-down) – Archisman Panigrahi May 31 '23 at 21:53
  • sadly no, that is the gui way of enabling it. I am asking about what is the command line equivalent of carrying it out. – Usermaxn May 31 '23 at 21:54
  • 1
    It's a feature provided by the plasma desktop which restore your previous session during login depending on wether it is enabled or not. There is no magic behind the buttons in the power menu. – mook765 Jun 01 '23 at 07:35
  • You have to re-formulate the question or it will be closed. The commands to shut down or restart etc have nothing to do with the session being saved or not (remembering applications.) So you maybe want to ask about a cli command that changes that session settings, not what you ask above. Running `systemsettings`, I see no changes when that settings is made. – cipricus Jun 01 '23 at 23:32
  • Looking at `systemsettings --help-all`, I see the option `--session ` `Restores the application from an earlier session` – cipricus Jun 01 '23 at 23:38

0 Answers0