How to swap text based on patterns at once with sed?
Maybe something like this: sed ‘s/ab/~~/g; s/bc/ab/g; s/~~/bc/g’ Replace ~ with a character that you know won’t be in the string.
Maybe something like this: sed ‘s/ab/~~/g; s/bc/ab/g; s/~~/bc/g’ Replace ~ with a character that you know won’t be in the string.
I’m using Visual Studio Code 1.8, and this feature is available. But it’s a little tricky to understand at first, and (at the time of writing) the docs don’t explain clearly how to use it, so here’s how it works, step by step: Invoke Replace in Files (under the Edit menu, or with shortcut Ctrl+Shift+H) … Read more