I recently moved to Elementary OS Luna. I especially use the Synapse Indicator launcher, because I like to work with my keyboard for everything.

In Synapse and in the Synapse Indicator (and I believe, generally, in the Gnome dekstop and I'll dare saying in all Linux DEs) there are "actions". Among actions there is Shut Down, Restart, Lock Screen etc. which can be run with Synapse and probably too from the command line.

I would like to create an action for Turn Off Screen (which is different from Lock Screen).

How can I create this action and be able to launch it from Synapse?

  • xset dpms off can turn off the screen. But how to achieve it with Synapse is out of my scope
    – SHW
    Oct 3, 2013 at 8:32
  • It's a start. I suspect there must be somewhere some "action" launcher? Much like there are application launchers? Oct 3, 2013 at 8:34
  • Never used Luna, so cant say about that. Not sure, but have a look in /etc/xdg/menus
    – SHW
    Oct 3, 2013 at 8:43
  • I did a little reading about Luna and my guess is you can't do it via synapse, but there seem to be other options for mounting a launcher on the desktop. What about a panel or the dock?
    – goldilocks
    Oct 3, 2013 at 9:59
  • Ideally I want to do that with my keyboard. Oct 3, 2013 at 10:43

2 Answers 2


Maybe there's a detail I'm missing here, but you can create a .desktop file for whatever shell script you like and Synapse will launch it for you no problem.


create a bash script file (.sh) then put this inside:

sleep 0; xset dpms force off

sleep 0 determine how fast it will turn off

put the file in home folder then set the executable properties (chmod +755)

i think any launcher app will recognize it as an action/runable.

to lock the screen while it turned off, you can add command to the script depend on your DE.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .