etc/vimrc

286 lines
7.3 KiB
VimL
Raw Normal View History

se nocompatible
call plug#begin('~/.vim/plugged')
Plug 'tpope/vim-sensible'
2015-02-16 19:04:52 +01:00
Plug 'ntpeters/vim-better-whitespace'
2015-03-14 10:10:15 +01:00
Plug 'nathanaelkane/vim-indent-guides'
2015-02-16 19:04:52 +01:00
2015-01-03 12:16:22 +01:00
Plug 'chrisbra/Recover.vim'
" Plug 'Valloric/YouCompleteMe', { 'do': './install.sh --clang-completer --system-libclang' }
Plug 'Shougo/vimproc.vim' , { 'do': 'make -f make_unix.mak' }
2016-01-17 19:48:09 +01:00
Plug 'junegunn/fzf', { 'dir': '~/.fzf' }
2016-01-05 09:26:26 +01:00
Plug 'junegunn/fzf.vim'
Plug 'ciaranm/securemodelines'
2014-08-10 09:25:50 +02:00
Plug 'chrisbra/SudoEdit.vim'
2014-08-18 16:42:57 +02:00
Plug 'majutsushi/tagbar'
Plug 'bling/vim-airline'
Plug 'tomtom/tcomment_vim'
2015-01-03 12:16:22 +01:00
" Plug 'jalcine/cmake.vim' --slow
2014-08-30 08:16:58 +02:00
2018-12-09 16:37:05 +01:00
" Plug 'roxma/nvim-completion-manager'
2016-01-02 13:51:29 +01:00
Plug 'editorconfig/editorconfig-vim'
" vim-sleuth?
Plug 'kchmck/vim-coffee-script'
2015-02-09 14:02:50 +01:00
Plug 'pangloss/vim-javascript'
Plug 'mtscout6/vim-cjsx'
Plug 'mxw/vim-jsx'
Plug 'othree/html5.vim'
Plug 'digitaltoad/vim-jade'
2020-07-15 11:51:36 +02:00
" Plug 'marijnh/tern_for_vim'
2015-02-09 14:02:50 +01:00
Plug 'ledger/vim-ledger'
2014-08-31 13:39:39 +02:00
Plug 'dag/vim2hs'
Plug 'eagletmt/ghcmod-vim'
Plug 'eagletmt/neco-ghc'
2014-06-01 14:13:23 +02:00
2015-01-03 12:16:22 +01:00
" clojure
Plug 'tpope/vim-leiningen'
Plug 'tpope/vim-projectionist'
Plug 'tpope/vim-dispatch'
Plug 'tpope/vim-fireplace'
2014-06-01 14:13:23 +02:00
Plug 'jnwhiteh/vim-golang'
Plug 'Blackrush/vim-gocode'
2014-06-01 14:13:23 +02:00
Plug 'zah/nimrod.vim'
2014-06-01 14:13:23 +02:00
Plug 'wting/rust.vim'
Plug 'racer-rust/vim-racer', { 'for': 'rust' }
2017-03-31 09:55:12 +02:00
Plug 'cespare/vim-toml'
2014-06-01 14:13:23 +02:00
Plug 'derekwyatt/vim-scala'
2016-07-24 18:50:21 +02:00
" Plug 'ensime/ensime-vim'
2014-06-01 14:13:23 +02:00
Plug 'dogrover/vim-pentadactyl'
Plug 'superbrothers/vim-vimperator'
2014-06-14 13:26:00 +02:00
Plug 'idris-hackers/idris-vim'
2014-07-13 13:29:14 +02:00
2019-04-14 14:21:58 +02:00
Plug 'tpope/vim-fugitive' " git integration
2019-03-15 10:42:57 +01:00
Plug 'jreybert/vimagit'
Plug 'airblade/vim-gitgutter'
2014-07-18 08:41:58 +02:00
2017-10-10 09:31:04 +02:00
Plug 'lervag/vimtex'
2018-10-05 10:46:26 +02:00
" Plug 'ludovicchabant/vim-gutentags'
Plug 'kana/vim-textobj-user'
Plug 'kana/vim-textobj-indent'
2015-03-13 19:13:54 +01:00
Plug 'rhysd/vim-grammarous'
2014-10-24 07:32:52 +02:00
Plug 'tpope/vim-surround'
2018-03-25 14:09:12 +02:00
Plug 'tpope/vim-characterize'
2014-10-24 07:32:59 +02:00
Plug 'peterhoeg/vim-qml'
2014-11-25 14:55:00 +01:00
Plug 'ekalinin/Dockerfile.vim'
2015-02-16 19:04:52 +01:00
Plug 'jvoorhis/coq.vim'
Plug 'LnL7/vim-nix'
2015-03-13 19:13:54 +01:00
2015-03-14 10:10:15 +01:00
Plug 'urbit/hoon.vim'
2015-07-12 15:34:07 +02:00
Plug 'ahf/twelf-syntax'
2015-09-15 19:20:37 +02:00
Plug 'c-cube/vim-tptp'
2019-04-07 14:06:33 +02:00
Plug 'sirtaj/vim-openscad'
2016-08-14 20:45:21 +02:00
Plug 'SirVer/ultisnips'
Plug 'honza/vim-snippets'
Plug 'nanotech/jellybeans.vim'
Plug 'sonph/onehalf', { 'rtp': 'vim' }
2016-08-14 20:45:21 +02:00
Plug '~/dgapt', { 'rtp': 'vim' }
2017-06-18 15:47:34 +02:00
" Plug '~/lean.vim'
Plug 'leanprover/lean.vim'
2020-06-25 14:03:49 +02:00
" Plug 'neoclide/coc.nvim', {'do': { -> coc#util#install()}}
2020-07-14 13:15:57 +02:00
" Plug 'autozimu/LanguageClient-neovim', { 'do': ':UpdateRemotePlugins' }
Plug 'Shougo/echodoc.vim'
2016-08-14 20:45:21 +02:00
2018-06-01 09:50:42 +02:00
Plug 'rickhowe/diffchar.vim'
2016-04-15 16:29:26 +02:00
Plug 'raichoo/smt-vim'
2016-07-24 18:50:12 +02:00
Plug 'tkztmk/vim-vala'
2018-03-25 14:09:12 +02:00
Plug 'wlangstroth/vim-racket'
2018-10-09 12:03:23 +02:00
Plug 'dag/vim-fish'
2020-07-14 17:49:29 +02:00
Plug 'elixir-editors/vim-elixir'
" Plug 'glacambre/firenvim', { 'do': { _ -> firenvim#install(0) } }
call plug#end()
2014-06-14 19:47:10 +02:00
filetype plugin indent on
2013-12-29 18:32:58 +01:00
set tw=0 expandtab ts=8 sts=2 sw=2 sm ai si
2014-08-18 16:42:57 +02:00
set noml mls=5 " scan 5 lines for modelines
syn on " enable syntax highlighting
set hls " highlight search
set bg=dark " dark background
2016-01-05 13:18:57 +01:00
se foldlevel=99
set vb " turn on the "visual bell" - which is much quieter than the "audio blink"
set nobackup
se bs=2
2019-10-01 10:51:51 +02:00
set backupcopy=yes
2019-03-13 10:24:12 +01:00
se inccommand=nosplit
set mouse=
2016-01-05 13:18:57 +01:00
set title
2019-03-11 11:44:44 +01:00
let g:jellybeans_overrides = {
\ 'background': { 'guibg': '000000' },
2021-04-02 21:29:09 +02:00
\ 'Normal': { 'guifg': 'ffffff' },
2019-03-11 11:44:44 +01:00
\}
if exists('g:started_by_firenvim')
set bg=light
colors onehalflight
else
colors jellybeans
endif
2019-03-13 10:23:00 +01:00
au syntax java setl ts=4 sts=4 sw=4
2016-01-05 13:18:57 +01:00
2019-03-13 10:23:00 +01:00
au BufNewFile,BufRead *.s setl ft=tptp
au BufNewFile,BufRead *.s.out setl ft=tptp
au BufNewFile,BufRead *.tptp setl ft=tptp
au BufNewFile,BufRead *.smt2 setl ft=smt
2016-01-05 13:18:57 +01:00
2013-03-29 15:24:24 +01:00
au BufReadCmd *.epub call zip#Browse(expand("<amatch>"))
2020-07-14 13:15:57 +02:00
au BufReadCmd *.FCStd call zip#Browse(expand("<amatch>"))
2016-01-05 13:18:57 +01:00
2016-01-08 09:34:05 +01:00
au FileType scala nnoremap <silent> <c-]> :EnDeclaration<cr>
2016-01-06 13:06:55 +01:00
2014-06-14 19:13:27 +02:00
au syntax haskell setl omnifunc=necoghc#omnifunc
2014-06-14 19:16:07 +02:00
let g:necoghc_enable_detailed_browse=1
2014-10-09 22:11:42 +02:00
let g:haskell_conceal = 0
2013-05-19 23:33:53 +02:00
2018-04-13 18:02:45 +02:00
call tcomment#type#Define('nix', '# %s')
call tcomment#type#Define('chaskell', '-- %s')
call tcomment#type#Define('vala', '// %s')
2020-06-25 14:03:57 +02:00
call tcomment#type#Define('tptp', '%% %s')
2017-10-10 09:31:04 +02:00
2016-01-05 13:18:57 +01:00
au syntax tex setl iskeyword+=:
au syntax tex syn region texZone start="\\begin{clilisting}" end="\\end{clilisting}\|%stopzone\>"
2016-04-15 16:29:26 +02:00
au syntax tex syn region texZone start="\\begin{tacticslisting}" end="\\end{tacticslisting}\|%stopzone\>"
au syntax tex syn region texZone start="\\begin{tacticsoutput}" end="\\end{tacticsoutput}\|%stopzone\>"
2015-11-26 21:45:12 +01:00
2014-09-28 09:31:52 +02:00
" disable annoying "file is read-only" warnings
au FileChangedRO * set noreadonly
2016-01-05 09:26:26 +01:00
nnoremap <c-p> :FZF<cr>
2017-06-18 15:47:34 +02:00
2017-10-10 09:31:04 +02:00
" nnoremap <silent> K :call LanguageClient_textDocument_hover()<CR>
" nnoremap <silent> gd :call LanguageClient_textDocument_definition()<CR>
2017-06-18 15:47:34 +02:00
" let g:cm_completekeys = "\<Plug>(cm_completefunc)"
2017-10-10 09:31:04 +02:00
" " call LanguageClient_setLoggingLevel('DEBUG')
" let g:LanguageClient_trace = 'verbose'
" let g:LanguageClient_autoStart = 1
" let g:LanguageClient_serverCommands = {
" \ 'lean': ['node', '/home/gebner/lean-client-js/lean-language-server/lib/index.js', '--stdio'],
" \ }
2017-10-13 08:27:20 +02:00
let g:gutentags_cache_dir="~/.config/nvim/gutentags"
2020-10-03 12:52:14 +02:00
let g:tex_flavor = 'latex'
2017-10-13 16:12:56 +02:00
let g:vimtex_compiler_progname = 'nvr'
2021-04-28 10:52:10 +02:00
let g:vimtex_indent_enabled = 0
au syntax tex setl indentexpr= " disable vim crap: https://github.com/lervag/vimtex/issues/2007#issuecomment-808768783
2017-10-10 09:31:04 +02:00
augroup my_cm_setup
autocmd!
autocmd User CmSetup call cm#register_source({
\ 'name' : 'vimtex',
\ 'priority': 8,
\ 'scoping': 1,
\ 'scopes': ['tex'],
\ 'abbreviation': 'tex',
\ 'cm_refresh_patterns': g:vimtex#re#ncm,
\ 'cm_refresh': {'omnifunc': 'vimtex#complete#omnifunc'},
\ })
augroup END
2020-06-25 14:03:49 +02:00
" " coc.nvim
"
"
" inoremap <silent><expr> <c-space> coc#refresh()
"
" " Use <cr> for confirm completion, `<C-g>u` means break undo chain at current position.
" " Coc only does snippet and additional edit on confirm.
" inoremap <expr> <cr> pumvisible() ? "\<C-y>" : "\<C-g>u\<CR>"
"
" " Use `[c` and `]c` for navigate diagnostics
" nmap <silent> [c <Plug>(coc-diagnostic-prev)
" nmap <silent> ]c <Plug>(coc-diagnostic-next)
"
" " Remap keys for gotos
" nmap <silent> gd <Plug>(coc-definition)
" nmap <silent> gy <Plug>(coc-type-definition)
" nmap <silent> gi <Plug>(coc-implementation)
" nmap <silent> gr <Plug>(coc-references)
"
" " Use K for show documentation in preview window
" nnoremap <silent> K :call <SID>show_documentation()<CR>
"
" function! s:show_documentation()
" if &filetype == 'vim'
" execute 'h '.expand('<cword>')
" else
" call CocAction('doHover')
" endif
" endfunction
"
" " Highlight symbol under cursor on CursorHold
" autocmd CursorHold * silent call CocActionAsync('highlight')
"
" " Remap for rename current word
" nmap <leader>rn <Plug>(coc-rename)
"
" " Remap for format selected region
" vmap <leader>f <Plug>(coc-format-selected)
" nmap <leader>f <Plug>(coc-format-selected)
"
" augroup mygroup
" autocmd!
" " Setup formatexpr specified filetype(s).
" autocmd FileType typescript,json setl formatexpr=CocAction('formatSelected')
" " Update signature help on jump placeholder
" autocmd User CocJumpPlaceholder call CocActionAsync('showSignatureHelp')
" augroup end
"
" " Remap for do codeAction of selected region, ex: `<leader>aap` for current paragraph
" vmap <leader>a <Plug>(coc-codeaction-selected)
" nmap <leader>a <Plug>(coc-codeaction-selected)
"
" " Remap for do codeAction of current line
" nmap <leader>ac <Plug>(coc-codeaction)
" " Fix autofix problem of current line
" nmap <leader>qf <Plug>(coc-fix-current)
"
" " Use `:Format` for format current buffer
" command! -nargs=0 Format :call CocAction('format')
"
" " Use `:Fold` for fold current buffer
" command! -nargs=? Fold :call CocAction('fold', <f-args>)