how to comment out multiple lines in vi editor?
Commenting Multiple Lines Then, press ctrl + v , this will enable the visual block mode. use the down arrow to select multiple lines that you want to comment. Now, press SHIFT + I to enable insert mode. Press # and it will add a comment to the first line.