0

I have the following script in a file:

#!/bin/bash
omxplayer --loop  --blank video.mp4

I double clicked the script and did execute instead of execute in terminal. I noticed I wasn't able to close the application.

For the purpose of learning, is there any way in that case to close the application?

ctrl + c does not work. Neither does esc.

1

You can hit q in omxplayer to exit. If you ever don't know how to close an application you can always use killall applicationname, so in this case you could have used killall omxplayer.

  • Why did someone downvote this? Looks like the right answer. – Dmitry Grigoryev Oct 24 '16 at 11:03
  • 1
    This is the edited answer, the previous answer was using killall which was not necessary as omxplayer has the q keybinding to exit. @DmitryGrigoryev – hazelnoot Oct 24 '16 at 11:23
  • But imho you could have let the kill part in the answer as an alternative, say if for whatever reason the keybinding is not set or simply for any other generic application. – Ghanima Oct 24 '16 at 11:37
  • Added it @Ghanima – hazelnoot Oct 24 '16 at 11:41
  • 1
    @clankill3r Many options, for example you could open a new SSH session, or connect a UART cable, or switch to a virtual terminal if you have a key binding for it. You could even assign a hotkey to killall omxplayer command, if it is often needed. – Dmitry Grigoryev Oct 24 '16 at 12:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.