>> How can I add some char before a block? Just like C++
>> comment.
> 
> Use V to select the block you want, then type :s/^/\/\//

You can make this a little easier/shorter to type by using

        :s!^!//

The alternative delimiters (you can use a variety of characters,
though I tend to choose "!", "@", or "#") allow you to include
certain characters without concern for having to escape the
primary delimiter.

There's also blockwise-visual mode:

        :help v_b_I

which can also be an easy/lazy way to do it, especially if you're
already in blockwise-visual mode.

-tim



Reply via email to