diff --git a/tycho/.vimrc b/tycho/.vimrc index 881fcaa..7789711 100644 --- a/tycho/.vimrc +++ b/tycho/.vimrc @@ -18,21 +18,24 @@ Plug 'morhetz/gruvbox' " Any valid git URL is allowed Plug 'https://github.com/scrooloose/nerdcommenter.git' -" On-demand loading +" On-demand loading for languages Plug 'rust-lang/rust.vim', { 'for': 'rust' } +Plug 'cespare/vim-toml', { 'for': 'toml' } +Plug 'keith/swift.vim', { 'for': 'swift' } Plug 'vim-syntastic/syntastic' -Plug 'cespare/vim-toml', { 'for': 'toml' } Plug 'vim-airline/vim-airline' Plug 'tpope/vim-fugitive' Plug 'airblade/vim-gitgutter' -Plug 'keith/swift.vim', { 'for': 'swift' } Plug 'justinmk/vim-sneak' Plug 'lervag/vimtex' Plug 'editorconfig/editorconfig-vim' +" Plug 'LnL7/vim-nix' +Plug 'preservim/nerdtree' " Plugin outside ~/.vim/plugged with post-update hook -Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' } +Plug 'junegunn/fzf', { 'do': { -> fzf#install() } } +Plug 'junegunn/fzf.vim' " ale language server client Plug 'dense-analysis/ale' @@ -40,6 +43,10 @@ Plug 'dense-analysis/ale' " Initialize plugin system call plug#end() +" open fzf files in new tab instead of new buffer +command! -bang -nargs=? -complete=dir Files + \ call fzf#vim#files(, {'sink': 'tabedit', 'options': ['--info=inline', '--preview', '~/.vim/plugged/fzf.vim/bin/preview.sh {}']}, 0) + set laststatus=2 let g:airline#extensions#tabline#enabled = 1 let g:airline_powerline_fonts = 1 @@ -67,6 +74,7 @@ au BufRead,BufNewFile *.ohuao setfiletype json " nnoremap \| map :tabp map :tabn +map f :Files " fix auto-completion set wildmenu " show a completion menu @@ -75,6 +83,9 @@ set wildignore=*.o,*~,*.pyc,*.aux,*.bbl,*.blg,*-blx.bib,*.log,*.out,*.run.xml, \*.toc,*.nav,*.snm " ignore auxiliary files " set completeopt-=preview +" automatically reload files changed on disk but not in buffer +set autoread + " tex configuration let g:tex_flavor='latex' " Optics