1

I was trying to bind a keyboard shortcut to my script. I tried binding it to keyboard shortcut from

System Settings>Keyboard>Shortcuts>Add Shortcut

I added new shortcut and as mentioned in this link I tried to add bash /path/to/my/script in the command section of the new shortcut. The permission is right.

It runs when I run from terminal.

I tried binding it using compiz-config-settings as mentioned in the answer given by n3rd. But it did not work.

this is my script.

2
  • here is my pastebin code
    – Pravin
    Apr 23, 2015 at 19:00
  • Just worked it out :) Might wanna delete comments!
    – Tim
    Apr 23, 2015 at 19:25

1 Answer 1

0

The command more doesn't seem to work.

Try changing each time it says more to cat.


How did I solve it?

I added this line after each if:

notify-send Alert No1

changing the number 1 to another number each time I used it. This showed me that the if then else statements weren't running. I then decided to change it to cat, because I use that and know it works!

notify-send

is a useful debugging tool for me. Have a look at it's man page to make it easier to use. If you can't use it, try to echo sometextNo1 > logfile.txt, and check that file.

0

You must log in to answer this question.

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