From 7009958502831c55cafb710cb5c425118d6e12ea Mon Sep 17 00:00:00 2001 From: Alexander M Pickering Date: Mon, 14 Aug 2023 13:33:16 -0500 Subject: updates --- nvim/init.vim | 67 ++++++++++++++++++++++++++++++----------------------------- 1 file changed, 34 insertions(+), 33 deletions(-) diff --git a/nvim/init.vim b/nvim/init.vim index 95a1410..69fe338 100644 --- a/nvim/init.vim +++ b/nvim/init.vim @@ -1,13 +1,18 @@ +"line numbers set nu +"unix newlines set ff=unix +"set the highlight column at 80 set colorcolumn=80 +" displace spaces, tabs, and newlines set list set listchars=tab:→\ ,space:·,nbsp:␣,trail:•,eol:¶,precedes:«,extends:» +"2 lines of cmd, needed for echodoc set cmdheight=2 if has('win32') source $VIMRUNTIME/mswin.vim endif -"let g:python3_host_prog='D:/Progams/Python/python.exe' +let g:python3_host_prog='python3' call plug#begin('~/.vim/plugged') @@ -39,11 +44,11 @@ Plug 'raimon49/requirements.txt.vim' Plug 'chrisbra/csv.vim' " Lua, Moonscript, Teal -"Plug 'xolox/vim-misc' -"Plug 'xolox/vim-lua-ftplugin' -"Plug 'VaiN474/vim-etlua' -"Plug 'leafo/moonscript-vim' -"Plug 'teal-language/vim-teal' +Plug 'xolox/vim-misc' +Plug 'xolox/vim-lua-ftplugin' +Plug 'VaiN474/vim-etlua' +Plug 'leafo/moonscript-vim' +Plug 'teal-language/vim-teal' "Plug 'whonore/Coqtail' @@ -63,7 +68,6 @@ Plug 'henrynewcomer/vim-theme-papaya' Plug 'sainnhe/edge' Plug 'kjssad/quantum.vim' Plug 'kyoz/purify' -Plug 'sainnhe/vim-color-atlantis' Plug 'jonathanfilip/vim-lucius' Plug 'joshdick/onedark.vim' Plug 'cocopon/iceberg.vim' @@ -71,7 +75,6 @@ Plug 'wolf-dog/sceaduhelm.vim' Plug 'danilo-augusto/vim-afterglow' Plug 'kamwitsta/mythos' Plug 'softmotions/vim-dark-frost-theme' -Plug 'sainnhe/vim-color-grimoire' Plug 'ghifarit53/tokyonight-vim' " Terraform @@ -82,8 +85,12 @@ colorscheme onedark "deoplete let g:deoplete#enable_at_startup = 1 -inoremap pumvisible() ? "\" : "\" -"autocmd CompleteDone * if pumvisible() == 0 | silent! pclose | endif +inoremap pumvisible() ? "\" : check_back_space() ? "\" : deoplete#manual_complete() +function s:check_back_space() abort "{{{ + let col = col('.') - 1 + return !col || getline('.')[col-1] =~ '\s' +endfunction"}}} +autocmd CompleteDone * if pumvisible() == 0 | silent! pclose | endif " echodoc let g:echodoc#enable_at_startup=1 @@ -91,16 +98,17 @@ let g:echodoc#type="floating" highlight link EchoDocFloat Pmenu "python -"let g:deoplete#sources#jedi#python_path='python3' +let g:deoplete#sources#jedi#python_path='python3' let g:deoplete#sources#jedi#enable_short_types=1 let g:deoplete#sources#jedi#show_docstring=1 call deoplete#custom#source('jedi','max_info_width',0) -"set completeopt-=preview +set completeopt-=preview "lua let g:lua_compiler_name='lua' "let g:lua_compiler_name='lua' let g:lua_complete_dynamic=1 +let g:lua_complete_keywords=0 au BufReadPost *.busted set syntax=lua au BufReadPost *.spec set syntax=lua au BufReadPost *.etlua set syntax=html @@ -129,15 +137,8 @@ nnoremap :call NERDComment('x', 'toggle') "Fuzzy file search let g:fzf_layout = { 'window': {'width': 0.9, 'height': 0.6} } -noremap π :call fzf#run(fzf#wrap({'sink': 'tabe', 'left': '20%', 'source': 'git ls-files'})) +noremap :call fzf#run(fzf#wrap({'sink': 'tabe', 'left': '20%', 'source': 'git ls-files'})) noremap :call fzf#run(fzf#wrap({'sink': 'vsplit', 'left': '50%', 'source': 'git ls-files'})) -noremap å :call fzf#run(fzf#wrap({'sink':'tabe', 'left': '20%', 'source': 'git ls-files'})) -command! -bang -nargs=* GAg - \ call fzf#vim#ag( - \ , - \ fzf#vim#with_preview(), - \ 0 - \) "Fuzzy git checkout branch noremap :call fzf#run(fzf#wrap({'sink': 'Git checkout', 'left':'20%', 'source': 'git branch --format "%(refname:short)"'})) @@ -173,15 +174,15 @@ nnoremap H 5h nnoremap L 5l "Navigate splits -tnoremap ˙ h -tnoremap ∆ j -tnoremap ˚ k -tnoremap ¬ l +tnoremap h +tnoremap j +tnoremap k +tnoremap l -nnoremap ˙ h -nnoremap ∆ j -nnoremap ˚ k -nnoremap ¬ l +nnoremap h +nnoremap j +nnoremap k +nnoremap l "Resize splits "noremap :vertical resize -5 @@ -216,14 +217,14 @@ nnoremap :call PushResize('k',5) nnoremap :call PushResize('l',5) "Navigate tabs -noremap ‘ gt -noremap “ gT +noremap gt +noremap gT "Add a semicolon at the end of the line vnoremap :'<,'>s/\([^;]\)$/\1;/g -"Build in a vertical split -noremap :vsplit term://make +"Vertical split and make +noremap :vsplit term://make all "Start a terminal noremap :vsplit:terminal @@ -232,7 +233,7 @@ noremap :vsplit:terminal noremap :Ag "Restart vim (alt+1) -noremap ¡ :source ~/.config/nvim/init.vim \| :PlugInstall +noremap :source $MYVIMRC \| :PlugInstall filetype plugin indent on syntax enable -- cgit v1.2.3-70-g09d2