Last active
August 29, 2015 14:20
-
-
Save dahu/84150fd3e33dea60c106 to your computer and use it in GitHub Desktop.
Fold consecutive comment lines
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| " Barry Arthur, April 2015 | |
| " Fold consecutive comment lines | |
| function! FoldComments() | |
| 1 | |
| while search('\(\n\s*\/\/\/\?.*\)\@<!\n\zs\s*\/\/\/\?', 'We') | |
| normal! vipzf | |
| endwhile | |
| endfunction |
Author
It starts from the first line in the buffer
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What does the 1 do there?