if exists("$VIRTUAL_ENV") let g:python3_host_prog=substitute(system("which -a python3 | head -n2 | tail -n1"), "\n", '', 'g') else let g:python3_host_prog=substitute(system("which python3"), "\n", '', 'g') endif runtime packages.vim let $MYVIMDIR=split(&rtp, ',')[0] set exrc set background=dark let g:chroma_italic_style="bold" let g:chroma_nontext_dark=1 colo chroma if exists("&cc") set cc=+1 endif set number set textwidth=80 set tabstop=2 set shiftwidth=2 set whichwrap+=<,>,h,l set notimeout set ttimeout set ttimeoutlen=50 set foldmethod=syntax set foldlevelstart=99 " disables visualbell set vb t_vb= set shellcmdflag=-c set shell=/bin/zsh set modeline set showcmd set ignorecase smartcase set inccommand=split set wildmode=list:longest,list:full set wildignore+=*.so,*.swp,*.zip,*.o set suffixes=.bak,~,.h,.info,.swp,.obj,.info,.aux,.dvi,.bbl,.out,.o,.lo,\.class set suffixes+=.pdf set wildmenu set hidden "set completeopt=menu,noinsert,preview "set completeopt=menuone,noinsert,noselect set completeopt=menu,menuone,noselect set shortmess+=c inoremap pumvisible() ? "\" : "\u\" set mouse= set cursorline set guicursor= set undofile set undodir=~/.local/share/nvim/undo set spelllang=de set termguicolors set pumblend=20 set updatetime=300 " custom commands command! RC edit $MYVIMRC command! SRC source $MYVIMRC command! CD :cd %:h command! PlugEdit edit $MYVIMDIR/packages.vim command! PlugReload source $MYVIMDIR/packages.vim | PlugInstall command! TrailingSpace %s/\s*$//g "{{{ latex " controls filetype setting, therefore not possible to move to ftplugin let g:tex_flavor = "latex" "}}} " {{{ misc Autocommands augroup Misc au FileType mail setlocal spell au FileType man setlocal nonu augroup END augroup Cache autocmd! autocmd BufRead,BufNewFile ~/Private/* setlocal directory=. augroup END "{{{ binary editing augroup Binary au! au BufReadPre *.bin let &bin=1 au BufReadPost *.bin if &bin | %!xxd au BufReadPost *.bin set ft=xxd | endif au BufWritePre *.bin if &bin | %!xxd -r au BufWritePre *.bin endif au BufWritePost *.bin if &bin | %!xxd au BufWritePost *.bin set nomod | endif augroup END "}}} "}}} " common mappings {{{ nnoremap za vnoremap . normal . noremap cy "*y tnoremap map h map j map k map l map < map > map - map + " navigate windows with alt+[hjkl] tnoremap h tnoremap j tnoremap k tnoremap l inoremap h inoremap j inoremap k inoremap l nnoremap h nnoremap j nnoremap k nnoremap l nnoremap :call search('^[^[:space:])\]}]', 'be') nnoremap :call search('^[^[:space:])\]}]', 'e') inoremap u nnoremap & :&& xnoremap & :&& nnoremap Y y$ inoremap nmap nohredraw! nmap imap vmap gs '<,'>sort "}}} "Git {{{ nmap gu Gina push nmap gvc !git svn dcommit nmap gvf !git svn fetch " Git }}} let g:signify_vcs_list = [ 'git', 'hg' ] "let g:signify_disable_by_default = 1 let g:localvimrc_whitelist='/home/crater2150/work/.*' let g:localvimrc_sandbox=0 lua require("my-lsp") lua require("lsputils") lua require("conf.cmp") lua require("conf.trouble") lua require("conf.treesitter") set foldmethod=expr set foldexpr=nvim_treesitter#foldexpr() set nofoldenable " Disable folding at startup. " vi:foldmethod=marker sw=2