martindoersch Posted July 17, 2022 Posted July 17, 2022 Hi! I want to create a workflow that copies a selected text (URL) alters this text (URL) - add a character at a specific location. (after the 16th character add a dash - ) pasts the altered text (URL) Do you have any suggestions for me, how to do this with workflows? Martin
vitor Posted July 17, 2022 Posted July 17, 2022 (edited) 2 hours ago, martindoersch said: copies a selected text (URL) Universal Action Trigger or Hotkey Trigger with Argument set to Selection in macOS. 2 hours ago, martindoersch said: alters this text (URL) - add a character at a specific location. (after the 16th character add a dash - ) Replace Utility set to “Replace regex (.{16})(.*) with $1-$2”. 2 hours ago, martindoersch said: pasts the altered text (URL) Copy to Clipboard Output (check Automatically paste to frontmost app). Edited July 17, 2022 by vitor martindoersch 1
martindoersch Posted July 18, 2022 Author Posted July 18, 2022 Hi! Thanks so much. This works. I just want to make it more effective for me by adding the following before/after: Keystroke CMD+L (activate URL in Browser) Copy the selection to clipboard do the string replacement with your regex Paste from clipboard Keystroke ENTER (to load the new url)
vitor Posted July 18, 2022 Posted July 18, 2022 4 hours ago, martindoersch said: Keystroke Dispatch Key Combo. You can also use an Automation Tasks to get the current tab URL.
martindoersch Posted July 23, 2022 Author Posted July 23, 2022 I found the Automation Tasks to be very handy.
vitor Posted July 23, 2022 Posted July 23, 2022 Great! Shouldn’t need the first one, though, as the second one already returns the URL upon closing the tab.
martindoersch Posted July 24, 2022 Author Posted July 24, 2022 Quote Great! Shouldn’t need the first one, though, as the second one already returns the URL upon closing the tab. Totally true!
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now