You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I take that back, it looks like I'm using my own fork of tpope's vim-surround with a fix that was rejected upstream that specifically enables integration with this plugin. I'll have to look into what that was even about so we can document how it should work together with that as well as vim-operator-surround.
Here's another alternative for future visitors to consider.
I use machakann/vim-sandwich. Although this plugin doesn't know about smart quotes out of the box, you can add custom recipes to vim-sandwich relatively easily.
Here's what I do.
" Save all default recipes to our newly defined batch of recipes.letg:sandwich#recipes =deepcopy(g:sandwich#default_recipes)
" Teach vim-sandwich about “foo” and ‘foo’letg:sandwich#recipes += [
\ {'buns': ['“', '”'], 'nesting': 0, 'input': ['q"']},
\ {'buns': ['‘', '’'], 'nesting': 0, 'input': ["q'"]},
\ ]
It'd be nice to use the https://github.com/rhysd/vim-operator-surround to add/replace quotes around text objects.
It likely involves an entry to
g:operator#surround#blocks
.The text was updated successfully, but these errors were encountered: