summaryrefslogtreecommitdiff
path: root/.vimrc
diff options
context:
space:
mode:
authorMarc Vertes <mvertes@free.fr>2023-05-15 18:23:57 +0200
committerMarc Vertes <mvertes@free.fr>2023-05-15 18:23:57 +0200
commit52f7b5658d303a0d49621c929cc65d81e52ff3fe (patch)
treec2afb0a49a073859e027c9a06dd829e9ffe20411 /.vimrc
parentf18d246634a9e47e9e3155996a77c17a170cf47a (diff)
improve formatting
Diffstat (limited to '.vimrc')
-rw-r--r--.vimrc22
1 files changed, 12 insertions, 10 deletions
diff --git a/.vimrc b/.vimrc
index c0007b0..2754e62 100644
--- a/.vimrc
+++ b/.vimrc
@@ -35,6 +35,7 @@ autocmd filetype vimki syntax on
autocmd filetype vimki set autowrite
" autocmd filetype vimki setlocal spell spelllang=fr
autocmd filetype vimki nmap <leader>z :FZF ~/Wiki<CR>
+autocmd filetype markdown,text,vimki setlocal textwidth=72
" vim-go plugin
"let g:go_def_mode = "gopls"
@@ -75,8 +76,9 @@ autocmd filetype python,yaml set ts=2 sts=2 sw=2 et
" noremap <M-f> :!cscope -7 <cfile>
" Paragraph format / unformat
-noremap <leader>f !}fmt
-noremap <leader>F !}fmt -c -w 2048
+" noremap <leader>f !}fmt
+" noremap <leader>F !}fmt -c -w 2048
+noremap <leader>f gqip
" noremap <buffer> K :s,^,//,
" noremap <buffer> <C-K> :s,^//,,
@@ -110,14 +112,14 @@ noremap <C-p> :Files<cr>
" 'i' includes: find files that include the filename under cursor
" 'd' called: find functions that function under cursor calls
-noremap <leader>s :cs find s <C-R>=expand("<cword>")<CR><CR><tab>
-noremap <leader>g :cs find g <C-R>=expand("<cword>")<CR><CR><tab>
-noremap <leader>c :cs find c <C-R>=expand("<cword>")<CR><CR><tab>
-noremap <leader>t :cs find t <C-R>=expand("<cword>")<CR><CR><tab>
-noremap <leader>e :cs find e <C-R>=expand("<cword>")<CR><CR><tab>
-noremap <leader>i :cs find i <C-R>=expand("<cfile>")<CR><CR><tab>
-noremap <leader>f :cs find f <C-R>=expand("<cfile>")<CR><CR><tab>
-noremap <leader>d :cs find d <C-R>=expand("<cword>")<CR><CR><tab>
+"noremap <leader>s :cs find s <C-R>=expand("<cword>")<CR><CR><tab>
+"noremap <leader>g :cs find g <C-R>=expand("<cword>")<CR><CR><tab>
+"noremap <leader>c :cs find c <C-R>=expand("<cword>")<CR><CR><tab>
+"noremap <leader>t :cs find t <C-R>=expand("<cword>")<CR><CR><tab>
+"noremap <leader>e :cs find e <C-R>=expand("<cword>")<CR><CR><tab>
+"noremap <leader>i :cs find i <C-R>=expand("<cfile>")<CR><CR><tab>
+"noremap <leader>f :cs find f <C-R>=expand("<cfile>")<CR><CR><tab>
+"noremap <leader>d :cs find d <C-R>=expand("<cword>")<CR><CR><tab>
function! CloseOnLast()