Adding a wildcard quote
This are some ideas inspired from vim-targets, I wonder if there is already a solution or if this could be easily implemented. Most of the time there is only one pair of surrounding objects in the line. Would it be possible to providing a "any quote" text object so we can do for example:
dsq: delete surrounding quotes
So if we have: this is an "example setence"
and we do dsq (delete surrounding quotes) it would become:
this is an example setence
no mater the cursor position at the line (just like in vim-targets)
similar for changing quotes, we don't need to hit the right key, just use the any quote and what we want:
So if we have: this is an "example setence"
and we do csq': change surrounding quotes with '
this is an 'example setence'
even cooler, we could add the next and last modifiers just like in vim-targets:
this is an 'example
if we do csnq": change surrounding next quotes with "
this is an 'example
Any guidance on how to achieve this or how to contribute to get closer to this would be very much appreciated.
+1
I am struggling with something similar - wanting to replace only the outermost quotes:
- "while ! (mongo --host mongo --eval "rs.initiate()"); do sleep 1; done"