Cycle Through Workspaces
Not long ago, my buddy Seth walked me through a bit of his Drafts setup. He's been creating a lot more workspaces as of late, but didn't think the workspace switching actions I had created before were enough, and he wanted a better way to cycle through them.
My coding skills aren't that great, and quite frankly, are rusty as hell because I haven't really done a lot of it due to other commitments. At the time, I was preparing for some big reviews at work, so I didn't even have time to look into it. Seth then reached out to the Drafts Community. It did take long before Jacob (jsamlarose) answered the call and created the action Seth requested. (Great work, Jacob!)
After discussing this over the phone with Seth, he was elated at his new method of switching. But he also wanted to cycle this in reverse as well. A quick search later, I found the .reverse()
javascript function, and simply added the line under the first line of the script. This reverses the array created in the line above, and then the rest of the script works in the same way. I ended up renaming the actions to Cycle Workspace FWD and Cycle Workspace REV and changing the icons used, along with changing the keyboard actions to ⌘→
and ⌘←
respectively.
This is just something simple that's really great and really effective. I think too often we can complicated the automation of different things and set our sights on creating complex actions (or shortcuts) to make our lives better. I'm finding that more and more, the simplest actions tend to be the right ones.