From 59725dfecdf3c0955983c11ff0822bf4bab9e0c5 Mon Sep 17 00:00:00 2001 From: Anton Bobov Date: Sun, 15 Nov 2020 23:52:02 +0500 Subject: Vim: update templates, config. --- files/.vimrc | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'files/.vimrc') diff --git a/files/.vimrc b/files/.vimrc index ddb4a54..251505d 100644 --- a/files/.vimrc +++ b/files/.vimrc @@ -313,14 +313,15 @@ if has('autocmd') au InsertEnter * set nocursorline au InsertLeave * set cursorline - " TODO перенести в ftplugin - autocmd FileType tex setlocal spell textwidth=79 - autocmd FileType java setlocal omnifunc=javacomplete#Complete - autocmd FileType python set expandtab - autocmd FileType html,xml,ant set nolist + " TODO перенести в ftplugin + au FileType tex setlocal spell textwidth=79 + au FileType java setlocal omnifunc=javacomplete#Complete + au FileType python set expandtab + au FileType html,xml,ant set nolist " Restore cursor position - au BufReadPost * if line("'\.") > 0 && line("'\.") <= line("$") | exe 'normal g`.zvzz' | endif + au BufReadPost * if line("'\"") > 0 && line("'\"") <= line("$") | exe 'normal g`"zvzz' | endif + au BufRead,BufNewFile /etc/nginx/* if &ft == "" | setfiletype nginx | endif au BufEnter * if &filetype == "" | setlocal ft=text | endif au BufReadPost *.ledger norm G @@ -328,7 +329,6 @@ if has('autocmd') au BufRead,BufNewFile *.geojson if &ft == "" | setfiletype json | endif " Set scripts to be executable from shell - "au BufWritePost * if getline(1) =~ "^#!.*/bin/" | silent !chmod +x | endif au BufWritePost * if getline(1) =~ "^#!.*/bin/" | silent exec "!chmod +x " | endif endif " }}} -- cgit v1.2.3