I copied this script, and it works great:
set myDoNotQuitList to {"Keyboard Maestro", "Chrome", "Script Editor", "Finder"}
tell application "System Events"
set quit delay to 0
set appList to name of processes whose background only is false
end tell
repeat with i in appList
if i is in myDoNotQuitList then set contents of i to 0
end repeat
set appList to text of appList
repeat with i in appList
tell application i to quit
end repeat
However, when I ran it the first time, I got a dialog box when trying to close Microsoft Teams, asking me which running app/process was associated with “Microsoft Teams”. I chose the wrong process.
My Question is: how do I reset this association, so I can associate the application name in my script with the correct process? I’m assuming it’s in a plist somewhere?
New contributor
John is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.