For a while now I have been assigning some of my personal shell scripts to keyboard shortcuts in Ubuntu (by going through Settings > Keyboard > Shortcuts and assigning them under Custom).
After upgrading to 15.10 however, I can no longer run shell scripts from keybaord shortcuts this way. Has the syntax changed, or are there new requirements? Previously, it had been enough for me to set the command as ~/myscript.sh
, but this no longer works.
My script has executable permissions, and running it from the command line is no problem. I have tried:
./myscript.sh
/home/me/myscript.sh
bash /home/me/myscript.sh
sh /home/me/myscript.sh
Among many other combinations of paths and commands. None of these have any response, and all of them work fine when pasted directly into the terminal. I have also tried assigning the script to other key combinations, but none of them have any response (though the key combinations themselves work fine if I assign another command that is not a shell script).
Running scripts this has been a crucial part of my daily workflow, so any suggestions would be appreciated. Thank you!
Alt+backslash
it will not work to run my script, but if I change it so the same key combination runs a different command that is not a shell script (e.g.,terminator
to launch the terminator app) it works for this command. However, I am at my work machine which is running on 15.04 still, and has the script bound toAlt+backslash
and working, and I realized that I have the keys bound to./myscript.sh
, which is the one combination I didn't try at home. Not sure why this would work, but will try tonight./myscript.sh
doesn't work either...gnome-settings-daemon
orunity-settings-daemon
form command line and then test the shortcuts, starting withbash -c /path/to/script.sh