Last active
April 4, 2024 14:23
-
-
Save lockieluke/9c7bead14114ecbfc52272608ac87714 to your computer and use it in GitHub Desktop.
Apple Script for pausing/resuming active primary timer on macOS with the Clock app
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tell application "Clock" | |
activate | |
end tell | |
tell application "System Events" | |
tell application process "Clock" | |
tell window 1 | |
# Go to Timers, 1 = World Clock and so on | |
click radio button 4 of radio group 1 of group 1 of toolbar 1 | |
# button 2 is pause, button 1 is cancel | |
click button 2 of group 2 of group 1 of group 1 of group 1 of group 1 of group 1 of group 1 of group 1 of group 1 of group 1 of group 1 of group 1 of group 1 | |
click button 1 | |
end tell | |
end tell | |
end tell |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment