In KDE setting you can assign a shortcut to execute your arbitrary command.
To assign a command to shortcut in KDE, you can do the following. In System Settings
-> Shortcuts
-> Custom Shortcuts
, right click, choose New
-> Global Shortcut
-> Command/URL
. Go to Action
tab and fill in the command. And in Trigger
tab assign the actual shortcut. And this mechanism works normally for the non-sudo commands.
But unfortunately, when I use the command that needs root privileges (let's assume sudo systemctl start something
), it is just not executed.
Is there a way to bypass this limitation? I want to be able to trigger action, that requires evaluated permissions.