Make improvements to .vimrc
This commit is contained in:
parent
5e5b1f4b2a
commit
e1ef4f14fb
38
vim/.vimrc
38
vim/.vimrc
|
@ -1,23 +1,53 @@
|
|||
set nocompatible
|
||||
|
||||
if filereadable(expand('~/.vim/autoload/plug.vim'))
|
||||
"let g:polyglot_disabled = ['markdown.plugin'] " Disable vim-polyglot's Markdown so we can use vim-pandoc instead
|
||||
|
||||
call plug#begin('~/.local/share/vim/plugins')
|
||||
" Syntax highlighting and language-specific rules
|
||||
Plug 'sheerun/vim-polyglot'
|
||||
Plug 'vim-pandoc/vim-pandoc'
|
||||
|
||||
" Snippets
|
||||
Plug 'SirVer/ultisnips'
|
||||
|
||||
" Web development
|
||||
Plug 'mattn/emmet-vim'
|
||||
|
||||
" Go programming
|
||||
Plug 'fatih/vim-go', { 'do': ':GoInstallBinaries' }
|
||||
|
||||
" Zettelkasten support
|
||||
Plug 'junegunn/fzf', { 'do': { -> fzf#install() } }
|
||||
Plug 'junegunn/fzf.vim'
|
||||
Plug '~/code/zk.vim/'
|
||||
call plug#end()
|
||||
|
||||
autocmd BufEnter ~/dox/zettelkasten/* set filetype=markdown
|
||||
" Ultisnips config
|
||||
let g:UltiSnipsSnippetsDir='~/.local/share/ultisnips'
|
||||
let g:UltiSnipsSnippetDirectories=['~/.local/share/ultisnips']
|
||||
let g:UltiSnipsExpandTrigger="<tab>"
|
||||
let g:UltiSnipsJumpForwardTrigger="<tab>"
|
||||
let g:UltiSnipsJumpBackwardTrigger="<s-tab>"
|
||||
let g:UltiSnipsEditSplit="context"
|
||||
else
|
||||
" Make tab = 4 spaces if vim-polyglot can't be loaded
|
||||
set tabstop=4
|
||||
set softtabstop=4
|
||||
set shiftwidth=4
|
||||
endif
|
||||
|
||||
" Autocommands
|
||||
autocmd BufEnter ~/.local/share/zk/* set filetype=markdown
|
||||
|
||||
" Enable line-numbering
|
||||
set number
|
||||
set relativenumber
|
||||
|
||||
" Use swap directory instead of cluttering source directories with swapfiles
|
||||
set directory^=$HOME/.vim/swap//
|
||||
|
||||
" Use system clipboard by default
|
||||
set clipboard=unnamedplus
|
||||
|
||||
" Make file searching better
|
||||
set wildmenu
|
||||
set wildmode=list:full
|
||||
set path+=**
|
||||
|
|
Loading…
Reference in New Issue