I want to close all windows appearing on my desktop. I've thought to do this through pkillpkill, but I could only manage to kill them one at a time, which is not what I want. The end goal is to put this into a script to run a kiosk, it will detect if the kiosk software is running (I figured this part out) and if it is not, then it will kill any windows that are open, and restart my kiosk software.
Thanks!