Close all open finder windows from terminal? I want to close all open finder windows from my terminal. I suppose I should use killall.. but then what?
Use AppleScript via osascript:

osascript -e 'tell application "Finder" to close windows'


killall is to kill applications, not close windows.