phitranphitranphitran / regexp-saver

VSCode extension for saving and re-using regular expressions
https://marketplace.visualstudio.com/items?itemName=phi.regexp-saver
MIT License
8 stars 2 forks source link

Feature request: enter regex without running it against all item #4

Closed acestronautical closed 2 years ago

acestronautical commented 4 years ago

it's nice to be able to save and run regexps, but sometimes I want to be able to audit which items are being replaced in the case of imperfect regex or nontrivial matching. If it's possible please add a copy to clipboard option, or even better have the regex and substitution populate into the search widget.

phitranphitranphitran commented 4 years ago

At the time this extension was made the Find and Replace widget exposed no APIs for any extension to access. I'm not sure if that's been changed since. The original plan was actually to read/write directly to the widget instead of using commands.

earendil1 commented 2 years ago

Hi, I have the same question. I was looking for such an extension, but the main drawback is not being able to use the replace command only when the replacement is pertinent, and when not, use only the find command.

phitranphitranphitran commented 2 years ago

Added new features in 1.1.0 - Find in File and Find in Selection. It populates the native Find and Replace widget. Please update and have a look!