-
Notifications
You must be signed in to change notification settings - Fork 219
"Replace All - Within Current Selection" only replaces a single match #1010
Comments
This has been driving me nuts too. Finding within a selection has been buggy for years (e.g. #298). Here's an example of a way in which this works sometimes, and not others. Working
Result: All matches in selection are replaced Not Working(Note, the steps are identical except steps 3 and 4 are reversed.)
Result: Only the final match (in the order the selection was made) is replaced. |
Another example, and one that is sporadic and hard to reproduce reliably...
So, the correct result, in the end, but an odd intermediate stage. However, sometimes it only replaces that first match, and not the others within the selection. And, sometimes, the selected area is displayed correctly. |
One more example of a slightly different oddness...
|
I am having this exact same problem and it is driving me nuts. I write in R, and was hoping to use atom instead of R-studio (hate) or sublime. Please fix this! It's a deal-breaker and pretty appalling for a text editor. This is the point of having a text editor! Ubuntu 16.04 |
Can confirm this is still an issue on 1.34.0 Mac. Workaround: While searching, Atom will highlight cases automatically within your selection. While not as visibly noticeable as hitting Find All and getting the selection set, you can still use this to verify your replacement set. Granted this only works for 3+ character strings, but at least you can still use Replace All with some modicum of comfort... |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Reproduced on macOS 10.12.6 with 1.39.0-nightly11:
2 results are reported after step 7 and then after step 8, only the second |
Edit by @rsese
Reproduced on macOS 10.12.6 with 1.39.0-nightly11:
Find And Replace: Show
Only in Selection
hello
and replace text tobye
Find All
Replace All
2 results are reported after step 7 and then after step 8, only the second
hello
is replaced:Prerequisites
Description
"replace all" only replace a single one whithin selection
Steps to Reproduce
--syntax
by.
Expected behavior: [What you expect to happen]
all --syntax should be replaced by
.
Actual behavior: [What actually happens]
only one --syntax is replaced
Reproduces how often: [What percentage of the time does it reproduce?]
5 times
Versions
windows 10
1.25.0
(by the way
atom --version
don't output anything in the cmd. Andapm --version
throw an error)Additional Information
screenshot:
The text was updated successfully, but these errors were encountered: