vim-commaobject icon indicating copy to clipboard operation
vim-commaobject copied to clipboard

dA, => delete argument and drop the ','

Open MarcWeber opened this issue 13 years ago • 2 comments

I find such mapping also deleting the , pretty useful when moving arguments first:

map dA, da,:let @* = substitute(@*, '^, \s*', ''", ''")<cr>

you may want to add it to the plugin file

MarcWeber avatar Nov 24 '12 05:11 MarcWeber

map dA, da,:let @* = substitute(substitute(@*, '^,\s*', '', ''), '\s*$', '', '')<cr>

even more useful also dropping trailing spaces. Thanks for the plugin

MarcWeber avatar Nov 24 '12 06:11 MarcWeber

Have a look and comment on this patch, please: https://github.com/MarcWeber/vim-commaobject/tree/rewrite-supporting-n-dropping

MarcWeber avatar Nov 24 '12 10:11 MarcWeber