Applescript To Close Most Tabs
I wrote this script in effort to have an applescript close all windows with more than one exception. For example, if I had 10 tabs open, I may want it to only leave three critical work tabs open.
This script works to close all but the link shown. I have not figured out how to get it to work on more than one tab.
Any suggestions would be appreciated.
tell application "Google Chrome"
set windowList to every tab of every window whose URL does not start with "https://mail.google.com"
repeat with tabList in windowList
set tabList to tabList as any
repeat with tabItr in tabList
set tabItr to tabItr as any
deletetabItr
end repeat
end repeat
end tell
Applescript-OTHER