From 4736c94869fd586a779e9a9cbbcc5eae8a6170a3 Mon Sep 17 00:00:00 2001 From: "(quasar) nebula" Date: Mon, 13 May 2024 20:09:03 -0300 Subject: vim: word wrap in text files --- .vimrc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.vimrc b/.vimrc index e2acbc9..fd195a9 100755 --- a/.vimrc +++ b/.vimrc @@ -173,6 +173,9 @@ autocmd FileType c,cpp,h,hpp set smartindent " word wrap javascript comments autocmd BufEnter,BufNew *.js autocmd CursorMoved,CursorMovedI * :if match(getline('.'), '^\s*//') == 0 | :setlocal textwidth=80 | :else | :setlocal textwidth=0 | :endif +" text (txt) overrides +au FileType text setlocal wrap + " yaml overrides au FileType yaml setlocal indentexpr= au FileType yaml nmap { ?---\+ -- cgit 1.3.0-6-gf8a5