I'm trying to comment multiple source code lines with following map:
vmap <leader>// :'<,'>-1s/^/\/\//
However it doesn't work. What's wrong?
|
I'm trying to comment multiple source code lines with following map:
However it doesn't work. What's wrong? |
||||
|
|
Try:
(You need to remove the range, because vmap does that automatically. Adding the This will only match lines that have one or more characters in it. That means it will skip the last line, but it also means it will skip empty lines...
This may be what you are specifically looking for:
The |
||||