reh said:Command-Shift-Option-Q will close all apps and log you out.
reh said:Another quick way of closing a lot of apps is through the Command-Tab application switcher. You can hit Q while each app is highlighted to close it. It's not a single key-stroke, but it's still pretty quick.
killall -u username
elbirth said:If you happened to be fairly observant during the WWDC keynote, one time when Steve got up from the computer after doing a demo of Spaces, he said "let me just go ahead and clean up these apps" and clicked an apple script icon in the dock on the far right-hand side that appeared to close all of the apps he had open (didn't just hide them, because the black triangles under the open apps went away). Later on at the beginning of the Core Animation demo, it looked like the mouse was still hovering over it and said "Close All"
So there's some way to at least do it via an apple script... anyone wanna poke around and find it out for sure?
Unorthodox said:This script will quit every open application that has a dock icon (except the Finder) and is NOT hidden.
So if you hide your apps a lot this script isn't for you.Code:tell application "Finder" set dock_app to the name of every process whose visible is true end tell repeat with num from 1 to number of items in the dock_app set this_app to item num of the dock_app if this_app is not "Finder" then tell application this_app quit end tell end if end repeat
Mitthrawnuruodo said:Now, the only thing might be to avoid that "hidden" restriction...
Mitthrawnuruodo said:He-he... that's how it's supposed to be. But if the application hasn't been launched yet (presumably since last login) it will start up when you run the tell application. Then once it has been quit it will ignore the telling...![]()
if application "whatever" is not {} then
tell application "whatever"
quit
end tell
end if
Since all of those little menubar apps (or any other little apps that sit in the background) are all hidden, quitting only the visible apps was the only thing I could think of.Mitthrawnuruodo said:Edit: But it seems Unorthodox' little script from the MR thread you found is the closest so far:
Now, the only thing might be to avoid that "hidden" restriction...
property noQuitList : {"Dock", "SystemUIServer", "loginwindow", "System Events", "Finder"}