Close all window in a window manager
Hi,
I'm looking for a script that close all the windows running in a window manager (icewm in my case). I found the following code in this forum: for app in `wmctrl `; do wmctrl -c "$app" done It closes some windows but not all (firefox with mutliple tabs open for instance asks for a confirmation). How to kill all the other windows once this firts script has been run ? Thanks for any help |
Just found an answer:
for app in `wmctrl -l `; do wmctrl -c "$app" done sleep 1 for app in ` wmctrl -l | cut -d' ' -f 1 `; do xkill -id "$app" done Howether, for the second part (killing the windows that did not closed in the first loop), I would prefer sending a SIGKILL signal, if someone has a soution how to do that.. |
All times are GMT -5. The time now is 09:55 AM. |