this adds a -s/--key-selector argument to the replace command. in
non-regexp mode, it will specify a complete key to match against. in
regexp mode, if the key selector yields any matches it will be
considered be successful. in this case, replacements will be evaluated
against that key-value pair. the key selector match will also be highlighted
in the display.
this pull also fixes two issues:
improper evaluation of the add/remove markup on a line diff during
replace
indexes being generated for regexps (index+length) did not match the
indexes being generated for substrings (start&end) resulting in a
panic for matches longer than half the string
this adds a
-s
/--key-selector
argument to thereplace
command. in non-regexp mode, it will specify a complete key to match against. in regexp mode, if the key selector yields any matches it will be considered be successful. in this case, replacements will be evaluated against that key-value pair. the key selector match will also be highlighted in the display.this pull also fixes two issues:
after confirmation: