diff --git a/.vim/autoload/plug.vim b/.vim/autoload/plug.vim index 652caa8..9c3011f 100644 --- a/.vim/autoload/plug.vim +++ b/.vim/autoload/plug.vim @@ -22,7 +22,7 @@ " Plug 'SirVer/ultisnips' | Plug 'honza/vim-snippets' " " " On-demand loading -" Plug 'scrooloose/nerdtree', { 'on': 'NERDTreeToggle' } +" Plug 'preservim/nerdtree', { 'on': 'NERDTreeToggle' } " Plug 'tpope/vim-fireplace', { 'for': 'clojure' } " " " Using a non-default branch diff --git a/.vimrc b/.vimrc index c804645..0f21efe 100644 --- a/.vimrc +++ b/.vimrc @@ -29,7 +29,7 @@ let g:vim_dir = $HOME . "/.vim" let mapleader="," fu! IsWindows() - if s:uname =~ "mingw" || s:uname =~ "msys" + if s:uname =~? "mingw" || s:uname =~? "msys" return 1 endif if has("win64") || has("win32") || has("win16") @@ -166,7 +166,7 @@ let g:campo_extensions_that_run_ctags = ['c','cpp','h','hpp','inc','cs','py','as " recursive crawl. " @note The CreateCtags function will always ignore .git and node_modules " regardless of this variable's value. -let g:campo_ctags_exclude = ['*.txt', '*.config', '.cache'] +let g:campo_ctags_exclude = ['*.txt', '*.config', '.cache', 'run_tree'] " This is included in the ctags autocmd args. You can use this to customize " how ctags are built. @@ -175,7 +175,7 @@ let g:campo_ctags_exclude = ['*.txt', '*.config', '.cache'] " * Create tags for specific langauges: `let g:campo_custom_ctags_args = '--languages=C,C++,Elixir' " * You can see a list of languages with `ctags --list-languages` " * For C# you have to escape the ampersand like so: `--languages=C\\#` -" * Exclude a directory with `let g:campo_custom_ctags_args = '--exclude=3rd_party'` +" * Exclude directories using g:campo_ctags_exclude let g:campo_custom_ctags_args = "" @@ -226,63 +226,44 @@ let g:campo_jai_metaprogram_args = '' call plug#begin('~/.vim/plugged') -"################################################################################## -" MISC -"################################################################################## +" I've locked the plugins to stable commits. No need to upgrade them unless there are bug fixes. -Plug 'vim-airline/vim-airline' " Enhanced status/tabline. -Plug 'embear/vim-localvimrc' " Add a .lvimrc to a folder to override .vimrc config. -Plug 'tpope/vim-obsession' " Continuously updated session files (tracks window positions, open folds, etc). -Plug 'tpope/vim-fugitive' " Git wrapper (I particularly like :Gblame, which I've wrapped as :Blame) -Plug 'sir-pinecone/vim-ripgrep' " Fast grep-like search. Requires ripgrep; install Rust package: `cargo install ripgrep`. -Plug 'itchyny/vim-cursorword' " Underlines all instances of the symbol under the cursor. -Plug 'airblade/vim-gitgutter' " Displays a git diff in the vim gutter and allows staging/unstaging of hunks. -Plug 'ctrlpvim/ctrlp.vim' " Fuzzy file, buffer, mru, tag, etc finder. -Plug 'majutsushi/tagbar' " Display ctags in a window, ordered by scope. -Plug 'tommcdo/vim-lion' " For text alignment, use gl= and gL= -Plug 'tpope/tpope-vim-abolish' " Easily search for, substitute, and abbreviate multiple variants of a word. Add them to `vim/after/plugin/abolish.vim` -Plug 'sir-pinecone/errormarker.vim' " Build error highlighting (requires skywind3000/asyncrun.vim). -Plug 'skywind3000/asyncrun.vim' " Async commands. -Plug 'nelstrom/vim-qargs' " For the GlobalReplaceIt function (i.e. search and replace). -Plug 'editorconfig/editorconfig-vim' " Adds support for .editorconfig files. +""""""""""""""""""" +" # MISC +""""""""""""""""""" +Plug 'sir-pinecone/errormarker.vim' " Build error highlighting (requires skywind3000/asyncrun.vim). +Plug 'sir-pinecone/vim-ripgrep' " Fast grep-like search. Requires ripgrep; install Rust package: `cargo install ripgrep`. +Plug 'sir-pinecone/vim-qargs', " For the GlobalReplaceIt function (i.e. search and replace). +Plug 'sir-pinecone/AnsiEsc.vim' " Ansi escape sequences concealed, but highlighted as specified. +Plug 'vim-airline/vim-airline', { 'commit': 'c7460aa' } " Enhanced status/tabline. +Plug 'embear/vim-localvimrc', { 'commit': '0206f5f' } " Add a .lvimrc to a folder to override .vimrc config. +Plug 'tpope/vim-fugitive', { 'commit': '46eaf89' } " Git wrapper (I particularly like :Gblame, which I've wrapped as :Blame) +Plug 'tpope/tpope-vim-abolish', { 'commit': 'dcbfe06' } " Search for, substitute, and abbreviate multiple variants of a word. Add to `after/plugin/abolish.vim` +Plug 'tpope/vim-obsession', { 'commit': 'fe9d3e1' } " @flagged for removal. Continuously updated session files (tracks window positions, open folds, etc). +Plug 'itchyny/vim-cursorword', { 'commit': '74a97c4' } " Underlines all instances of the symbol under the cursor. Requires a ctags file. +Plug 'ctrlpvim/ctrlp.vim', { 'commit': '7c972cb' } " (prev stable: d93d978) Fuzzy file, buffer, mru, tag, etc finder. +Plug 'skywind3000/asyncrun.vim', { 'commit': '61cc308' } " (prev stable: 58d23e7) Async commands. +Plug 'airblade/vim-gitgutter', { 'commit': 'fe0e8a2' } " Displays a git diff in the vim gutter and allows staging/unstaging of hunks. +Plug 'majutsushi/tagbar', { 'commit': '5d6990e' } " Generates ctags on-demand and shows the current file's symbols. Doesn't support existing ctag files, so no Jai support. +Plug 'tommcdo/vim-lion', { 'commit': 'ce46593' } " For text alignment, use gl= and gL= +Plug 'editorconfig/editorconfig-vim', { 'commit': '95cb75e' } " Adds support for .editorconfig files. -" @flagged for removal -Plug 'sir-pinecone/AnsiEsc.vim' " Ansi escape sequences concealed, but highlighted as specified. +""""""""""""""""""" +" # SYNTAX +""""""""""""""""""" +Plug 'sir-pinecone/jai.vim' " Jai +Plug 'sir-pinecone/fasm.vim' " Flat Assembler +Plug 'bfrg/vim-cpp-modern', { 'commit': 'cc7019b' } " C/C++ +Plug 'elixir-editors/vim-elixir', { 'commit': '6dd03f8' } " Elixir +Plug 'pprovost/vim-ps1', { 'commit': '308aac5' } " PowerShell +Plug 'tpope/vim-markdown', { 'commit': 'f2b82b7' } " Markdown +"Plug 'vim-ruby/vim-ruby' { 'commit': 'f06f069' } " Ruby -if IsWindows() - Plug 'suxpert/vimcaps' " Disable capslock (useful if the OS isn't configured to do so). -endif - -"################################################################################## -" COLORS -"################################################################################## - -Plug 'vim-airline/vim-airline-themes' - -if IsWindows() - Plug 'godlygeek/csapprox' " Try to make gvim themes look decent on Windows. -endif - -Plug 'dracula/vim', { 'as': 'dracula' } - -"///////////////////////////////////////////////// -" SYNTAX HIGHLIGHTING -"///////////////////////////////////////////////// - -Plug 'rluba/jai.vim' " Jai -Plug 'bfrg/vim-cpp-modern' " C/C++ -Plug 'fedorenchik/fasm.vim' " Flat Assembler -Plug 'elixir-editors/vim-elixir' " Elixir -Plug 'pprovost/vim-ps1' " PowerShell -Plug 'tpope/vim-markdown' " Markdown -"Plug 'vim-ruby/vim-ruby' " Ruby -"Plug 'fatih/vim-go' " Go -"Plug 'rust-lang/rust.vim' " Rust -"Plug 'jdonaldson/vaxe' " Haxe - -" -" -" +""""""""""""""""""" +" # THEMES +""""""""""""""""""" +Plug 'vim-airline/vim-airline-themes', { 'commit': '04fa4fc' } +Plug 'dracula/vim', { 'commit': '6495b4f', 'as': 'dracula' } call plug#end() filetype plugin indent on @@ -1471,6 +1452,7 @@ nnoremap p (&buftype is# "quickfix" ? "\|:copen" : "p") " @warning I've stopped using this because it sometimes locks up vim and I " have to force exit the process then clean up the swap files. +" " @improve Figure out what's causing vim to freeze and fix it. Seems to happen " when it quickly changes and saves a handful of buffers. @@ -1530,7 +1512,7 @@ fu! GlobalReplaceIt(confirm_replacement) range call PrintError("Unable to search since you're not in a git repo!") endif endfu -noremap r :call GlobalReplaceIt(0) +noremap r :call GlobalReplaceIt(0) noremap rr :call GlobalReplaceIt(1)