Open CBenoit opened 2 years ago
How should this behaviour interact with the undo? Add the change only to the alread open buffers?
I think this solution is quite dirty, but it is the best that comes to my mind. I think that letting this feature to be handled by external programs would be a better choice.
One approach I've seen before is a prompt where you'd say if to open all files when replacing (adding to undo buffer) or replace without opening (no undo). The prompt can be handled in many other ways of course, just that it's an explicit choice. Personally I'd say this is an expected feature in any IDE, so I vote yay. (:
Open a buffer for the result, any changes on that buffer would effect related files? This can undo, something like https://github.com/mhayashi1120/Emacs-wgrep
What we need is something like Vim’s cdo
command, which allows user to apply Ex command to every entry in the quickfix list.
My suggestion, add a simple command call run-macro-on-last-picker
.
The plan is very much something like https://github.com/helix-editor/helix/pull/4381 that would leverage helixes existing multi-cursor support. That PR just needs a better PR and for that larger changes are likely needed
Add some form of support for global search-and-replace.
Discussed in https://github.com/helix-editor/helix/discussions/3793