I need to simulate the behavior of the keyboard shortcut (ALT+F4) using Terminal for a given application.
If I open for example gedit and click ALT + F4 , then GEDIT will be xkilled. If I want to achieve same thing using Terminal, how should I proceed?
The following command (in order to kill gedit process) works fine:
kill $eval `pidof gedit`
yet, the command
xkill -id gedit
prompts me to click on the application client window in order to xkill it, thing That I want to avoid from the beginning.
The reason why I want to achieve this behavior is that some applications clients keep their process running, even though you ALT+F4 it. My need is that I have an application that starts up on every login and I need to automatically close its client 3 or 5 seconds after it shows up.
xkill
when we want to make sure an appliciation is terminated.