2020-06-26 21:23:12 +00:00
|
|
|
" Plug
|
2020-09-04 10:02:34 +00:00
|
|
|
let plug_install = 0
|
|
|
|
let autoload_plug_path = stdpath('data') . '/site/autoload/plug.vim'
|
|
|
|
if !filereadable(autoload_plug_path)
|
|
|
|
silent exe '!curl -fL --create-dirs -o ' . autoload_plug_path .
|
|
|
|
\ ' https://raw.github.com/junegunn/vim-plug/master/plug.vim'
|
|
|
|
execute 'source ' . fnameescape(autoload_plug_path)
|
|
|
|
let plug_install = 1
|
2020-06-26 21:23:12 +00:00
|
|
|
endif
|
2020-09-04 10:02:34 +00:00
|
|
|
unlet autoload_plug_path
|
2020-06-26 21:23:12 +00:00
|
|
|
|
|
|
|
call plug#begin()
|
|
|
|
|
|
|
|
" Editing
|
|
|
|
" text objects
|
2021-05-08 17:58:12 +00:00
|
|
|
Plug 'xeruf/argtextobj.vim' " arguments in brackets as text objects
|
2020-09-04 10:02:34 +00:00
|
|
|
Plug 'tpope/vim-surround' " edit surroundings - cs, ds, ys
|
|
|
|
Plug 'bkad/CamelCaseMotion' " move through camel case words
|
2020-06-26 21:23:12 +00:00
|
|
|
" commands
|
|
|
|
Plug 'inkarkat/vim-ReplaceWithRegister' " gr to replace with register
|
2022-03-25 08:14:30 +00:00
|
|
|
Plug 'Konfekt/vim-sentence-chopper' " gw for sembr
|
2020-06-26 21:23:12 +00:00
|
|
|
Plug 'tpope/vim-commentary' " gc to comment out (gcap for paragraph)
|
2021-07-10 19:47:54 +00:00
|
|
|
Plug 'junegunn/vim-easy-align' " gaip*= - align in paragraph all equal signs
|
2020-06-26 21:23:12 +00:00
|
|
|
xmap ga <Plug>(EasyAlign)
|
|
|
|
nmap ga <Plug>(EasyAlign)
|
|
|
|
" libs
|
|
|
|
Plug 'tpope/vim-repeat'
|
|
|
|
Plug 'inkarkat/vim-ingo-library'
|
|
|
|
|
|
|
|
" Ex commands
|
2021-12-10 11:49:02 +00:00
|
|
|
Plug 'DataWraith/auto_mkdir' " mkdir parent dirs when saving
|
|
|
|
Plug 'AndrewRadev/bufferize.vim' " Command to buffer
|
|
|
|
Plug 'tpope/vim-eunuch' " OS helpers
|
|
|
|
Plug 'doy/vim-diff-changes' " Commands for diffing - :DiffAgainstFilesystem :DiffAgainstVCS :DiffStop
|
2020-06-26 21:23:12 +00:00
|
|
|
|
|
|
|
" QOL
|
2021-12-10 11:49:02 +00:00
|
|
|
Plug 'farmergreg/vim-lastplace' " Automatically jump to last edit position
|
|
|
|
Plug 'chrisbra/Recover.vim' " Add Recover options for swap files
|
|
|
|
Plug 'ntpeters/vim-better-whitespace' " Tools for trailing whitespace & mixed indents
|
2020-06-26 21:23:12 +00:00
|
|
|
|
|
|
|
" Aesthetic
|
2021-12-10 11:49:02 +00:00
|
|
|
Plug 'vim-airline/vim-airline' " Status bar on the bottom
|
|
|
|
set noshowmode " Don't show current m ode because airline already does and it inhibits echo in visual mode
|
|
|
|
Plug 'romainl/vim-cool' " Automatically stop highlighting search results when moving - https://stackoverflow.com/questions/657447/vim-clear-last-search-highlighting
|
|
|
|
Plug 'norcalli/nvim-colorizer.lua' " Highlight color literals
|
|
|
|
Plug 'luochen1990/indent-detector.vim' " Auto-detect indent
|
2020-06-26 21:23:12 +00:00
|
|
|
" Visual indent guides
|
|
|
|
Plug 'nathanaelkane/vim-indent-guides'
|
|
|
|
let g:indent_guides_enable_on_vim_startup = 1
|
2022-01-19 16:05:56 +00:00
|
|
|
Plug 'mhinz/vim-signify' " VCS info on the left
|
2020-06-26 21:23:12 +00:00
|
|
|
|
|
|
|
" Integrations
|
2022-01-19 16:05:56 +00:00
|
|
|
"Plug 'airblade/vim-gitgutter' " Git info on the left and hunk bindings
|
2022-03-14 20:23:59 +00:00
|
|
|
Plug 'tpope/vim-fugitive' " Difftool usage
|
2022-01-19 19:09:56 +00:00
|
|
|
Plug 'xeruf/vim-fossil'
|
2021-10-31 19:22:16 +00:00
|
|
|
Plug 'austintraver/vim-jrnl'
|
2022-03-14 20:23:59 +00:00
|
|
|
Plug 'weinshec/vim-dictcc' " TODO do not hang without internet
|
2020-06-26 21:23:12 +00:00
|
|
|
Plug 'glacambre/firenvim', { 'do': { _ -> firenvim#install(0) } }
|
2021-12-10 11:49:02 +00:00
|
|
|
Plug 'mipmip/vim-scimark' " Edit markdown tables with sc-im
|
2020-06-26 21:23:12 +00:00
|
|
|
|
|
|
|
call plug#end()
|
|
|
|
|
2020-09-04 10:02:34 +00:00
|
|
|
" Install plugins automatically after installing plug
|
|
|
|
if plug_install
|
|
|
|
PlugInstall --sync
|
|
|
|
endif
|
|
|
|
unlet plug_install
|