]> git.rmz.io Git - dotfiles.git/commitdiff
vim: auto-wrap comments, don't insert comment leader
authorSamir Benmendil <me@rmz.io>
Thu, 27 Aug 2015 00:16:38 +0000 (01:16 +0100)
committerSamir Benmendil <me@rmz.io>
Thu, 27 Aug 2015 01:33:49 +0000 (02:33 +0100)
vim/vimrc

index 86d5bfbc85c293684283924e12fa4bb4105ff1de..8160348d9a899b53ef50a93d7843708f657b6263 100644 (file)
--- a/vim/vimrc
+++ b/vim/vimrc
@@ -172,6 +172,8 @@ set formatoptions+=r    " Insert comment leader after hitting <Enter>
 set formatoptions+=n    " Recognize numbered lists
 set formatoptions+=q    " Allow formatting of comments with "gq".
 set formatoptions+=l    " do not wrap lines that have been longer when starting insert mode already
+set formatoptions+=t    " Auto-wrap text using textwidth
+set formatoptions-=o    " Do not insert comment leader after hitting o or O in normal mode
 
 set nrformats=hex               " number formats recognized for CTRL-A and CTRL-X commands