2017-02-14 20:51:44 +01:00
|
|
|
" Specify a directory for plugins (for Neovim: ~/.local/share/nvim/plugged)
|
|
|
|
call plug#begin('~/.config/nvim/plugged')
|
|
|
|
|
|
|
|
" Automatically match brackets as you type
|
|
|
|
Plug 'Raimondi/delimitMate'
|
2017-10-19 11:12:12 +02:00
|
|
|
" Tab completion
|
|
|
|
Plug 'ervandew/supertab'
|
2017-02-14 20:51:44 +01:00
|
|
|
" EasyMotion - Allows <leader><leader>(b|e) to jump to (b)eginning or (end)
|
|
|
|
" of words.
|
|
|
|
Plug 'easymotion/vim-easymotion'
|
2019-01-25 06:19:07 +01:00
|
|
|
" Fuzzy file search
|
2019-02-12 18:43:38 +01:00
|
|
|
"Plug '~/.fzf'
|
2019-01-25 06:19:07 +01:00
|
|
|
Plug 'junegunn/fzf.vim'
|
2017-02-14 20:51:44 +01:00
|
|
|
" Remove extraneous whitespace when edit mode is exited
|
|
|
|
Plug 'thirtythreeforty/lessspace.vim'
|
|
|
|
" Status bar mods
|
|
|
|
Plug 'bling/vim-airline'
|
|
|
|
Plug 'airblade/vim-gitgutter'
|
|
|
|
" Manage Project sessions
|
2017-10-19 11:12:12 +02:00
|
|
|
Plug 'tpope/vim-obsession'
|
|
|
|
Plug 'dhruvasagar/vim-prosession'
|
2017-02-14 20:51:44 +01:00
|
|
|
" Explore filesystem
|
|
|
|
Plug 'scrooloose/nerdtree'
|
2017-02-15 10:23:41 +01:00
|
|
|
" Commenter
|
|
|
|
Plug 'scrooloose/nerdcommenter'
|
|
|
|
" Theme
|
|
|
|
Plug 'sickill/vim-monokai'
|
2018-11-14 15:13:47 +01:00
|
|
|
" Autoload and read from dish if file changes
|
|
|
|
Plug 'tmux-plugins/vim-tmux-focus-events'
|
2018-11-21 17:51:14 +01:00
|
|
|
" For LaTeX support
|
2019-07-05 06:57:52 +02:00
|
|
|
Plug 'lervag/vimtex'
|
2019-01-25 06:19:07 +01:00
|
|
|
" For git support
|
2019-07-05 19:30:05 +02:00
|
|
|
Plug 'tpope/vim-fugitive'
|
|
|
|
Plug 'junegunn/gv.vim'
|
2019-06-27 18:36:14 +02:00
|
|
|
Plug 'rhysd/git-messenger.vim'
|
2019-07-05 19:30:05 +02:00
|
|
|
Plug 'sodapopcan/vim-twiggy'
|
|
|
|
Plug 'christoomey/vim-conflicted'
|
2019-01-27 18:19:26 +01:00
|
|
|
" For tmux yank
|
|
|
|
Plug 'vim-utils/vim-husk'
|
2019-09-25 05:34:51 +02:00
|
|
|
" Tags
|
|
|
|
Plug 'ludovicchabant/vim-gutentags'
|
2019-08-02 20:58:42 +02:00
|
|
|
" GDB
|
|
|
|
Plug 'sakhnik/nvim-gdb', { 'do': ':!./install.sh \| UpdateRemotePlugins' }
|
2019-02-12 09:23:56 +01:00
|
|
|
" Lisp
|
2019-02-18 18:34:03 +01:00
|
|
|
Plug 'eraserhd/parinfer-rust', { 'do': 'cargo build --release' }
|
2019-10-05 22:25:28 +02:00
|
|
|
Plug 'Olical/vim-scheme', { 'for': 'scheme', 'on': 'SchemeConnect' }
|
|
|
|
Plug 'guns/vim-sexp'
|
|
|
|
Plug 'tpope/vim-sexp-mappings-for-regular-people'
|
|
|
|
Plug 'wlangstroth/vim-racket'
|
2019-02-12 09:23:56 +01:00
|
|
|
" Haskell
|
|
|
|
Plug 'neovimhaskell/haskell-vim', { 'for': [ 'haskell', 'cabal' ] }
|
2019-07-04 18:13:19 +02:00
|
|
|
Plug 'parsonsmatt/intero-neovim'
|
|
|
|
Plug 'neomake/neomake'
|
2019-07-11 12:26:36 +02:00
|
|
|
Plug 'autozimu/LanguageClient-neovim' , {
|
|
|
|
\ 'branch' : 'next',
|
|
|
|
\ 'do' : './install.sh'
|
|
|
|
\ }
|
2019-02-14 10:00:24 +01:00
|
|
|
" For autocompletion
|
|
|
|
Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' }
|
2019-03-06 16:36:57 +01:00
|
|
|
" Autocomplete for Python
|
|
|
|
Plug 'zchee/deoplete-jedi'
|
|
|
|
" Autocomplete for Rust
|
|
|
|
Plug 'sebastianmarkow/deoplete-rust'
|
|
|
|
Plug 'rust-lang/rust.vim'
|
2019-08-28 20:23:21 +02:00
|
|
|
" Erlang Support
|
|
|
|
Plug 'vim-erlang/vim-erlang-tags'
|
|
|
|
Plug 'vim-erlang/vim-erlang-runtime'
|
|
|
|
Plug 'vim-erlang/vim-erlang-omnicomplete'
|
|
|
|
Plug 'vim-erlang/vim-erlang-compiler'
|
2019-06-30 19:13:19 +02:00
|
|
|
" Miscellaneous
|
|
|
|
Plug 'tpope/vim-surround'
|
|
|
|
Plug 'editorconfig/editorconfig-vim'
|
|
|
|
Plug 'tpope/vim-eunuch'
|
2019-07-05 19:30:05 +02:00
|
|
|
Plug 'jeetsukumaran/vim-buffergator'
|
2019-09-25 11:13:58 +02:00
|
|
|
Plug 'vim-utils/vim-man'
|
|
|
|
Plug 'unblevable/quick-scope'
|
2017-02-14 20:51:44 +01:00
|
|
|
|
|
|
|
" Initialize plugin system
|
|
|
|
call plug#end()
|
|
|
|
|
|
|
|
syntax on
|
2017-10-19 11:12:12 +02:00
|
|
|
filetype plugin indent on
|
2017-02-14 20:51:44 +01:00
|
|
|
|
|
|
|
" Set up leaders
|
|
|
|
let mapleader="\<SPACE>"
|
|
|
|
|
2019-09-25 05:34:51 +02:00
|
|
|
set colorcolumn=80 " Highlight 80th column
|
|
|
|
set laststatus=2 " Always show status bar
|
|
|
|
set updatetime=500 " Let plugins show effects after 500ms
|
|
|
|
set mouse-=a " Disable mouse click to go to position
|
2017-02-14 20:51:44 +01:00
|
|
|
set encoding=utf-8
|
2019-01-24 15:13:30 +01:00
|
|
|
set exrc " Allow loading local .nvimrc files
|
|
|
|
set secure " Disallow use of autocmd, shell and write in local rc
|
2017-02-14 20:51:44 +01:00
|
|
|
set showcmd " Show (partial) command in status line.
|
|
|
|
set showmatch " Show matching brackets.
|
|
|
|
set showmode " Show current mode.
|
|
|
|
set ruler " Show the line and column numbers of the cursor.
|
|
|
|
set number " Show the line numbers on the left side.
|
|
|
|
set formatoptions+=o " Continue comment marker in new lines.
|
|
|
|
set textwidth=0 " Hard-wrap long lines as you type them.
|
2018-10-26 17:16:21 +02:00
|
|
|
set softtabstop=4 " Finetunes the amount of white space to be added.
|
2017-02-14 20:51:44 +01:00
|
|
|
set tabstop=4 " Render TABs using this many spaces.
|
2017-02-18 12:30:11 +01:00
|
|
|
set shiftwidth=4 " Indentation amount for < and > commands.
|
2018-10-26 17:16:21 +02:00
|
|
|
set smarttab " Indent with tabs, align with spaces.
|
|
|
|
set expandtab " When on, uses space instead of tabs.
|
2017-02-14 20:51:44 +01:00
|
|
|
set noerrorbells " No beeps.
|
|
|
|
set modeline " Enable modeline.
|
|
|
|
set linespace=0 " Set line-spacing to minimum.
|
|
|
|
set nojoinspaces " Prevents inserting two spaces after punctuation on a join (J)
|
|
|
|
set splitbelow " Horizontal split below current.
|
|
|
|
set splitright " Vertical split to right of current.
|
|
|
|
|
|
|
|
if !&scrolloff
|
|
|
|
set scrolloff=3 " Show next 3 lines while scrolling.
|
|
|
|
endif
|
|
|
|
if !&sidescrolloff
|
|
|
|
set sidescrolloff=5 " Show next 5 columns while side-scrolling.
|
|
|
|
endif
|
|
|
|
set nostartofline " Do not jump to first character with page commands.
|
|
|
|
|
|
|
|
set ignorecase " Make searching case insensitive
|
|
|
|
set smartcase " ... unless the query has capital letters.
|
|
|
|
set gdefault " Use 'g' flag by default with :s/foo/bar/.
|
|
|
|
set magic " Use 'magic' patterns (extended regular expressions).
|
2018-11-14 15:13:47 +01:00
|
|
|
set autoread " Autoload file if it changes on disk
|
2019-08-12 07:34:20 +02:00
|
|
|
set termguicolors " Enable colors for terminal
|
2019-02-11 16:26:11 +01:00
|
|
|
|
2019-09-25 05:34:51 +02:00
|
|
|
set clipboard^=unnamed,unnamedplus
|
|
|
|
set completeopt=menuone,preview,noinsert
|
2019-02-12 18:43:38 +01:00
|
|
|
set rtp+=/usr/bin/fzf
|
2017-02-14 20:51:44 +01:00
|
|
|
|
2019-09-25 05:34:51 +02:00
|
|
|
" Theme
|
|
|
|
syntax enable
|
|
|
|
colorscheme monokai
|
2018-10-14 15:40:12 +02:00
|
|
|
|
2017-02-14 20:51:44 +01:00
|
|
|
" Use <C-L> to clear the highlighting of :set hlsearch.
|
|
|
|
if maparg('<C-L>', 'n') ==# ''
|
|
|
|
nnoremap <silent> <C-L> :nohlsearch<CR><C-L>
|
|
|
|
endif
|
|
|
|
|
2017-03-29 13:05:42 +02:00
|
|
|
"nnoremap ; : " Use ; for commands.
|
|
|
|
"nnoremap Q @q " Use Q to execute default register.
|
2017-02-14 20:51:44 +01:00
|
|
|
|
|
|
|
" Open NerdTree
|
|
|
|
nnoremap <Leader>n :NERDTree<CR>
|
2019-02-12 06:17:10 +01:00
|
|
|
" Open fuzzy file search
|
2019-07-05 19:30:05 +02:00
|
|
|
nnoremap <Leader>f :Files<CR>
|
2019-08-01 08:47:06 +02:00
|
|
|
nnoremap <Leader>gf :GFiles<CR>
|
2019-06-30 19:13:19 +02:00
|
|
|
" Use ripgrep to search for content in files
|
|
|
|
nnoremap <Leader>/ :Rg<CR>
|
2019-08-12 07:06:10 +02:00
|
|
|
" Save
|
|
|
|
nnoremap <Leader>w <Esc>:w<CR>
|
|
|
|
" Search and Replace
|
|
|
|
nmap <Leader>s :%s//g<Left><Left>
|
|
|
|
" Quit
|
|
|
|
nnoremap <Leader>q <Esc>:q<CR>
|
|
|
|
" Search for the word under cursor
|
|
|
|
noremap <Leader>d :exe ':Rg ' . expand('<cword>')<CR>
|
2019-06-27 18:36:14 +02:00
|
|
|
" For git messenger
|
|
|
|
nnoremap <Leader>gm :GitMessenger<CR>
|
|
|
|
|
2017-02-18 12:30:11 +01:00
|
|
|
" Key Bindings to help with terminal mode
|
2017-08-04 13:08:35 +02:00
|
|
|
:tnoremap <Esc> <C-\><C-n>
|
2017-10-19 11:12:12 +02:00
|
|
|
" Key bindings to move between window splits
|
|
|
|
nnoremap <A-h> <C-w>h
|
|
|
|
nnoremap <A-j> <C-w>j
|
|
|
|
nnoremap <A-k> <C-w>k
|
|
|
|
nnoremap <A-l> <C-w>l
|
2017-02-18 12:30:11 +01:00
|
|
|
|
2017-03-29 13:05:42 +02:00
|
|
|
" Disable Arrow Keys
|
|
|
|
inoremap <Up> <NOP>
|
|
|
|
inoremap <Down> <NOP>
|
|
|
|
inoremap <Left> <NOP>
|
|
|
|
inoremap <Right> <NOP>
|
|
|
|
noremap <Up> <NOP>
|
|
|
|
noremap <Down> <NOP>
|
|
|
|
noremap <Left> <NOP>
|
|
|
|
noremap <Right> <NOP>
|
|
|
|
|
2019-09-09 18:43:27 +02:00
|
|
|
nnoremap <Leader>ld :call LanguageClient#textDocument_definition()<CR>
|
|
|
|
nnoremap <Leader>lr :call LanguageClient#textDocument_rename()<CR>
|
|
|
|
nnoremap <Leader>lf :call LanguageClient#textDocument_formatting()<CR>
|
|
|
|
nnoremap <Leader>lt :call LanguageClient#textDocument_typeDefinition()<CR>
|
|
|
|
nnoremap <Leader>lx :call LanguageClient#textDocument_references()<CR>
|
|
|
|
nnoremap <Leader>la :call LanguageClient_workspace_applyEdit()<CR>
|
|
|
|
nnoremap <Leader>lc :call LanguageClient#textDocument_completion()<CR>
|
|
|
|
nnoremap <Leader>lh :call LanguageClient#textDocument_hover()<CR>
|
|
|
|
nnoremap <Leader>ls :call LanguageClient_textDocument_documentSymbol()<CR>
|
|
|
|
nnoremap <Leader>lm :call LanguageClient_contextMenu()<CR>
|
2019-07-11 12:26:36 +02:00
|
|
|
nnoremap <Leader>la :call LanguageClient#textDocument_codeAction()<CR>
|
|
|
|
|
2019-09-09 18:43:27 +02:00
|
|
|
" https://github.com/autozimu/LanguageClient-neovim/issues/618
|
|
|
|
function! LspMaybeHover(is_running) abort
|
|
|
|
if a:is_running.result && g:LanguageClient_autoHoverAndHighlightStatus
|
|
|
|
call LanguageClient_textDocument_hover()
|
|
|
|
endif
|
|
|
|
endfunction
|
|
|
|
|
|
|
|
function! LspMaybeHighlight(is_running) abort
|
|
|
|
if a:is_running.result && g:LanguageClient_autoHoverAndHighlightStatus
|
|
|
|
call LanguageClient#textDocument_documentHighlight()
|
|
|
|
endif
|
|
|
|
endfunction
|
|
|
|
|
|
|
|
augroup lsp_aucommands
|
|
|
|
au!
|
|
|
|
au CursorHold * call LanguageClient#isAlive(function('LspMaybeHover'))
|
|
|
|
au CursorMoved * call LanguageClient#isAlive(function('LspMaybeHighlight'))
|
|
|
|
augroup END
|
|
|
|
|
|
|
|
let g:LanguageClient_autoHoverAndHighlightStatus = 0
|
|
|
|
|
|
|
|
function! ToggleLspAutoHoverAndHilight() abort
|
|
|
|
if g:LanguageClient_autoHoverAndHighlightStatus
|
|
|
|
let g:LanguageClient_autoHoverAndHighlightStatus = 0
|
|
|
|
call LanguageClient#clearDocumentHighlight()
|
|
|
|
echo ""
|
|
|
|
else
|
|
|
|
let g:LanguageClient_autoHoverAndHighlightStatus = 1
|
|
|
|
end
|
|
|
|
endfunction
|
|
|
|
nnoremap <Leader>lg :call ToggleLspAutoHoverAndHilight()<CR>
|
|
|
|
|
2019-07-04 18:13:19 +02:00
|
|
|
augroup interoMaps
|
|
|
|
au!
|
|
|
|
" Maps for intero. Restrict to Haskell buffers so the bindings don't collide.
|
|
|
|
|
|
|
|
" Background process and window management
|
|
|
|
au FileType haskell nnoremap <silent> <leader>is :InteroStart<CR>
|
2019-07-08 19:46:05 +02:00
|
|
|
au FileType haskell nnoremap <silent> <leader>ir :InteroRestart<CR>
|
2019-07-04 18:13:19 +02:00
|
|
|
au FileType haskell nnoremap <silent> <leader>ik :InteroKill<CR>
|
|
|
|
|
|
|
|
" Open intero/GHCi split horizontally
|
|
|
|
au FileType haskell nnoremap <silent> <leader>io :InteroOpen<CR>
|
|
|
|
" Open intero/GHCi split vertically
|
|
|
|
au FileType haskell nnoremap <silent> <leader>iov :InteroOpen<CR><C-W>H
|
|
|
|
au FileType haskell nnoremap <silent> <leader>ih :InteroHide<CR>
|
|
|
|
|
|
|
|
" Reloading (pick one)
|
|
|
|
" Automatically reload on save
|
2019-07-07 10:27:57 +02:00
|
|
|
" au BufWritePost *.hs InteroReload
|
2019-07-04 18:13:19 +02:00
|
|
|
" Manually save and reload
|
|
|
|
au FileType haskell nnoremap <silent> <leader>wr :w \| :InteroReload<CR>
|
|
|
|
|
|
|
|
" Load individual modules
|
|
|
|
au FileType haskell nnoremap <silent> <leader>il :InteroLoadCurrentModule<CR>
|
|
|
|
au FileType haskell nnoremap <silent> <leader>if :InteroLoadCurrentFile<CR>
|
|
|
|
|
|
|
|
" Type-related information
|
|
|
|
" Heads up! These next two differ from the rest.
|
|
|
|
au FileType haskell map <silent> <leader>it <Plug>InteroGenericType
|
|
|
|
au FileType haskell map <silent> <leader>T <Plug>InteroType
|
|
|
|
au FileType haskell nnoremap <silent> <leader>iit :InteroTypeInsert<CR>
|
|
|
|
|
|
|
|
" Navigation
|
2019-07-09 06:49:13 +02:00
|
|
|
au FileType haskell nnoremap <silent> <leader>id :InteroGoToDef<CR>
|
2019-07-04 18:13:19 +02:00
|
|
|
|
|
|
|
" Managing targets
|
|
|
|
" Prompts you to enter targets (no silent):
|
|
|
|
au FileType haskell nnoremap <leader>ist :InteroSetTargets<SPACE>
|
|
|
|
augroup END
|
|
|
|
|
2019-09-24 17:15:37 +02:00
|
|
|
augroup deopleteMaps
|
|
|
|
au!
|
|
|
|
" For deoplete Rust
|
|
|
|
au FileType rust nmap <buffer> <Leader>rd <plug>DeopleteRustGoToDefinitionDefault
|
|
|
|
au FileType rust nmap <buffer> <Leader>rc <plug>DeopleteRustShowDocumentation
|
|
|
|
au FileType rust nmap <buffer> <Leader>rv <plug>DeopleteRustGoToDefinitionVSplit
|
|
|
|
au FileType rust nmap <buffer> <Leader>rh <plug>DeopleteRustGoToDefinitionSplit
|
|
|
|
au FileType rust nmap <buffer> <Leader>rt <plug>DeopleteRustGoToDefinitionTab
|
|
|
|
augroup END
|
|
|
|
|
2019-10-05 22:25:28 +02:00
|
|
|
" Starts the REPL.
|
|
|
|
autocmd FileType scheme nnoremap <buffer> <Leader>rc :SchemeConnect<cr>
|
|
|
|
" Evaluates the outer most / top level form and jumps the cursor back to where it was.
|
|
|
|
autocmd FileType scheme nnoremap <buffer> <Leader>re :normal mscpaF<cr>`s
|
|
|
|
" Evaluates the entire file.
|
|
|
|
autocmd FileType scheme nnoremap <buffer> <Leader>rf :normal msggcpG<cr>`s
|
|
|
|
|
2019-09-25 05:34:51 +02:00
|
|
|
" Run gofmt on save
|
|
|
|
autocmd BufWritePre *.go :call LanguageClient#textDocument_formatting_sync()
|
|
|
|
|
|
|
|
" For Clojure
|
|
|
|
function! Expand(exp) abort
|
|
|
|
let l:result = expand(a:exp)
|
|
|
|
return l:result ==# '' ? '' : "file://" . l:result
|
|
|
|
endfunction
|
|
|
|
|
|
|
|
nnoremap <silent> crcc :call LanguageClient#workspace_executeCommand('cycle-coll', [Expand('%:p'), line('.') - 1, col('.') - 1])<CR>
|
|
|
|
nnoremap <silent> crth :call LanguageClient#workspace_executeCommand('thread-first', [Expand('%:p'), line('.') - 1, col('.') - 1])<CR>
|
|
|
|
nnoremap <silent> crtt :call LanguageClient#workspace_executeCommand('thread-last', [Expand('%:p'), line('.') - 1, col('.') - 1])<CR>
|
|
|
|
nnoremap <silent> crtf :call LanguageClient#workspace_executeCommand('thread-first-all', [Expand('%:p'), line('.') - 1, col('.') - 1])<CR>
|
|
|
|
nnoremap <silent> crtl :call LanguageClient#workspace_executeCommand('thread-last-all', [Expand('%:p'), line('.') - 1, col('.') - 1])<CR>
|
|
|
|
nnoremap <silent> crml :call LanguageClient#workspace_executeCommand('move-to-let', [Expand('%:p'), line('.') - 1, col('.') - 1, input('Binding name: ')])<CR>
|
|
|
|
nnoremap <silent> cril :call LanguageClient#workspace_executeCommand('introduce-let', [Expand('%:p'), line('.') - 1, col('.') - 1, input('Binding name: ')])<CR>
|
|
|
|
nnoremap <silent> crel :call LanguageClient#workspace_executeCommand('expand-let', [Expand('%:p'), line('.') - 1, col('.') - 1])<CR>
|
|
|
|
nnoremap <silent> cram :call LanguageClient#workspace_executeCommand('add-missing-libspec', [Expand('%:p'), line('.') - 1, col('.') - 1])<CR>
|
|
|
|
|
|
|
|
let g:LanguageClient_autoStart = 0
|
|
|
|
let g:LanguageClient_loggingFile = expand('$HOME/LC.log')
|
|
|
|
let g:LanguageClient_rootMarkers = ['stack.yaml']
|
|
|
|
let g:LanguageClient_serverCommands = {
|
|
|
|
\ 'haskell': ['$HOME/.local/bin/hie-wrapper'],
|
|
|
|
\ 'go' : ['$HOME/go/bin/gopls'],
|
|
|
|
\ 'clojure': ['bash', '-c', 'clojure-lsp'],
|
|
|
|
\ }
|
|
|
|
|
|
|
|
let g:haskell_enable_quantification = 1 " to enable highlighting of `forall`
|
|
|
|
let g:haskell_enable_recursivedo = 1 " to enable highlighting of `mdo` and `rec`
|
|
|
|
let g:haskell_enable_arrowsyntax = 1 " to enable highlighting of `proc`
|
|
|
|
let g:haskell_enable_pattern_synonyms = 1 " to enable highlighting of `pattern`
|
|
|
|
let g:haskell_enable_typeroles = 1 " to enable highlighting of type roles
|
|
|
|
let g:haskell_enable_static_pointers = 1 " to enable highlighting of `static`
|
|
|
|
let g:haskell_backpack = 1 " to enable highlighting of backpack keywords
|
|
|
|
|
|
|
|
let g:haskell_classic_highlighting = 1
|
|
|
|
let g:haskell_indent_if = 3
|
|
|
|
let g:haskell_indent_case = 2
|
|
|
|
let g:haskell_indent_let = 4
|
|
|
|
let g:haskell_indent_where = 6
|
|
|
|
let g:haskell_indent_before_where = 2
|
|
|
|
let g:haskell_indent_after_bare_where = 2
|
|
|
|
let g:haskell_indent_do = 3
|
|
|
|
let g:haskell_indent_in = 1
|
|
|
|
let g:haskell_indent_guard = 2
|
|
|
|
let g:haskell_indent_case_alternative = 1
|
|
|
|
let g:cabal_indent_section = 2
|
|
|
|
|
|
|
|
" Intero starts automatically. Set this if you'd like to prevent that.
|
|
|
|
let g:intero_start_immediately = 0
|
|
|
|
" Enable type information on hover (when holding cursor at point for ~1 second).
|
|
|
|
let g:intero_type_on_hover = 0
|
|
|
|
" Change the intero window size; default is 10.
|
|
|
|
let g:intero_window_size = 15
|
|
|
|
" Sets the intero window to split vertically; default is horizontal
|
|
|
|
let g:intero_vertical_split = 1
|
|
|
|
|
2019-02-14 10:00:24 +01:00
|
|
|
" Use deoplete
|
|
|
|
let g:deoplete#enable_at_startup = 1
|
2019-09-24 17:15:37 +02:00
|
|
|
" Disable autocomplete by default
|
|
|
|
" let b:deoplete_disable_auto_complete = 1
|
|
|
|
" let g:deoplete_disable_auto_complete = 1
|
|
|
|
" Let sources be empty by default
|
|
|
|
let g:deoplete#sources = {}
|
|
|
|
" Disable the candidates in Comment/String syntaxes.
|
|
|
|
call deoplete#custom#source('_',
|
|
|
|
\ 'disabled_syntaxes', ['Comment', 'String'])
|
|
|
|
call deoplete#custom#option('sources', {
|
2019-09-25 05:34:51 +02:00
|
|
|
\ '_' : ['buffer', 'tag'],
|
2019-09-24 17:15:37 +02:00
|
|
|
\ 'rust': ['racer'],
|
|
|
|
\ 'haskell': ['LanguageClient'],
|
|
|
|
\ 'go': ['LanguageClient'],
|
|
|
|
\ 'clojure': ['LanguageClient'],
|
|
|
|
\})
|
|
|
|
let g:deoplete#sources#rust#disable_keymap = 1
|
2019-09-25 05:34:51 +02:00
|
|
|
let g:deoplete#sources#rust#racer_binary=expand('$HOME/.cargo/bin/racer')
|
|
|
|
let g:deoplete#sources#rust#rust_source_path=expand('$HOME/GitSources/rust/src')
|
2017-02-18 12:30:11 +01:00
|
|
|
|
2019-07-04 18:13:19 +02:00
|
|
|
" Use airline
|
2017-02-14 20:51:44 +01:00
|
|
|
let g:airline#extensions#tabline#enabled = 2
|
|
|
|
let g:airline#extensions#tabline#fnamemod = ':t'
|
|
|
|
let g:airline#extensions#tabline#left_sep = ' '
|
|
|
|
let g:airline#extensions#tabline#left_alt_sep = '|'
|
|
|
|
let g:airline#extensions#tabline#right_sep = ' '
|
|
|
|
let g:airline#extensions#tabline#right_alt_sep = '|'
|
|
|
|
let g:airline_left_sep = ' '
|
|
|
|
let g:airline_left_alt_sep = '|'
|
|
|
|
let g:airline_right_sep = ' '
|
|
|
|
let g:airline_right_alt_sep = '|'
|
2019-02-11 16:26:11 +01:00
|
|
|
|
2019-07-05 19:30:05 +02:00
|
|
|
" Let vim-gitgutter do its thing on large files
|
|
|
|
let g:gitgutter_max_signs=10000
|
2019-08-28 20:23:21 +02:00
|
|
|
|
2019-09-25 05:34:51 +02:00
|
|
|
" gutentags configuration
|
|
|
|
" https://www.reddit.com/r/vim/comments/d77t6j/guide_how_to_setup_ctags_with_gutentags_properly/
|
|
|
|
let g:gutentags_add_default_project_roots = 0
|
|
|
|
let g:gutentags_project_root = ['.git']
|
2019-09-30 18:46:54 +02:00
|
|
|
let g:gutentags_cache_dir = expand('$HOME/.vim/tags/')
|
2019-09-25 05:34:51 +02:00
|
|
|
|
|
|
|
let g:gutentags_generate_on_new = 1
|
|
|
|
let g:gutentags_generate_on_missing = 1
|
|
|
|
let g:gutentags_generate_on_write = 1
|
|
|
|
let g:gutentags_generate_on_empty_buffer = 0
|
|
|
|
|
|
|
|
let g:gutentags_ctags_extra_args = [
|
|
|
|
\ '--tag-relative=yes',
|
|
|
|
\ '--fields=+ailmnS',
|
|
|
|
\ ]
|