When I need to test a form while developing, I was really bored and too lazy to think of some text to fill in any text input. Things like
sajklhdas are too messy, and even though I have LittleIpsum installed it still takes too many clicks and mouse dragging. There must be a better way. I thought about using a timestamp.
So I found this post. Easy handmade service could do the job. Here’s how to set it up.
- Launch Automator.app, add new Service.
- Search for Run Shell Script and fill in
date "+%Y-%m-%d %T", I’m using
/bin/zshby the way.
- At the upper Service receives section, select no input and any application, also check Output replaces selected text.
- Save the service, I named it Insert Timestamp.
- Now go to System Preferences and Keyboard, in the Keyboard Shortcuts tab you will find your newly created service within the Text dropdown. Check to activate it and assign a keyboard shortcut. I use
cmd + ctrl + shift + Dfor my setup.
And that’s it! Let’s enjoy this little handy trick ;)