^⌘U
- because life's too short to type ISO-8601 timestamps manually
Writing timestamps is annoying - especially when you often need to type the timestamp of now.
After installing the script and configuring the shortcut you can use
^⌘u
(Control
+Command
+U
) to pasted the current timestamp into the cursor's position.
- OSX (tested with 10.12 - Sierra)
- open the
Automator
application - create a new
Service
via menuFile
,New
- configure
Service Reveives
tono input
- drag the
Run AppleScript
action into the right area
- copy-paste the content of paste-a-timestamp.scpt snippet into the AppleScript
- save the AppleScript as
paste-a-timestamp
via menuFile
,Save
- open the
Keybord
settings underSystem Preference
- in tab
Shortcuts
search for thepaste-a-timestamp
service - double-click on the
none
text to record the shortcut you want to use - e.g.^⌘U
(Control
+Command
+U
)
- open the
Security & Privacy
settings underSystem Preference
- in tab
Privacy
and settingAccessibility
allow theAutomator
application to control your computer
Therefore open the lock in the lower-left corner
- after the setup process it may need some minutes until it works until it works in all applications - for whatever reason
- the shortcut will not work in an application that overwrites it - Then you have to change the paste-a-timestamp shortcut or reconfigure the application