X-Git-Url: https://git.sthu.org/?a=blobdiff_plain;f=plugins-noroot-nolowendbox.vim;h=d665a29f9e1454dd4176ce96227a051dfc74633f;hb=72cdf2b3eafef9025ec012c5b179625e125b1744;hp=602724ec11f19477ea6c69579e2bf9ba02494d8a;hpb=16bc2290e1fad3db8a4116f5c61df91d9fd02b12;p=vimconf.git diff --git a/plugins-noroot-nolowendbox.vim b/plugins-noroot-nolowendbox.vim index 602724e..d665a29 100644 --- a/plugins-noroot-nolowendbox.vim +++ b/plugins-noroot-nolowendbox.vim @@ -13,6 +13,7 @@ endif Plug 'artur-shaik/vim-javacomplete2', {'for': 'java'} Plug 'neomake/neomake' +Plug 'puremourning/vimspector' " Prevent slow foling update, e.g., for vimtex Plug 'Konfekt/FastFold' @@ -40,21 +41,21 @@ else endif Plug 'ryanoasis/vim-devicons', Cond(g:enable_plugin_devicons) -Plug 'joom/latex-unicoder.vim', {'on': 'Unicoder'} +Plug 'joom/latex-unicoder.vim' +Plug 'chrisbra/unicode.vim' Plug 'sjl/splice.vim', {'on': 'SpliceInit'} " Costs a second startup time Plug 'dbeniamine/cheat.sh-vim', {'on': 'Cheat'} +Plug 'sheerun/vim-polyglot' + if has('nvim-0.5') Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'} Plug 'nvim-treesitter/nvim-treesitter-refactor', {'do': ':TSUpdate'} -else - Plug 'sheerun/vim-polyglot' endif - function PluginsNorootNolowendboxConfig() let g:neomake_c_enabled_makers = ['clangtidy', 'clangcheck'] let g:neomake_cpp_enabled_makers = ['clangtidy', 'clangcheck'] @@ -240,4 +241,38 @@ EOF let g:vimtex_fold_enabled = 1 let g:vimtex_fold_levelmarker = '➜' + au FileType c,cpp,obj,java,python packadd! vimspector + let g:vimspector_base_dir = expand('~/.vim/vimspector-config') + let g:vimspector_install_gadgets = [ 'debugpy', 'vscode-cpptools' ] + "let g:vimspector_enable_mappings = 'VISUAL_STUDIO' + + function VimspectorRestartOrCreateConfig() + if !filereadable('.vimspector.json') + echo "Missing .vimspector.json, created one." + execute 'tabe .vimspector.json' + else + call vimspector#Restart() + endif + endfunction + + nmap dc VimspectorContinue + nmap ds VimspectorStop + nmap dr :call VimspectorRestartOrCreateConfig() + "nmap dr :call vimspector#Restart() + nmap drr :call vimspector#Reset() + nmap dp VimspectorPause + nmap db VimspectorToggleBreakpoint + nmap dcb VimspectorToggleConditionalBreakpoint + nmap dfb VimspectorAddFunctionBreakpoint + nmap dtc VimspectorRunToCursor + nmap do VimspectorStepOver + nmap di VimspectorStepInto + nmap dof VimspectorStepOut + " for normal mode, the word under the cursor + nmap de VimspectorBalloonEval + " for visual mode, the visually selected text + xmap de VimspectorBalloonEval + + au BufNewFile .vimspector.json read ~/.vim/vimspector-config/vimspector.json + endfunction