call plug#begin() Plug 'junegunn/fzf.vim' Plug 'sheerun/vim-polyglot' Plug 'dracula/vim' Plug 'preservim/nerdtree' Plug 'neoclide/coc.nvim', {'branch': 'release'} call plug#end() map :NERDTreeToggle "" Turn-on dracula color scheme syntax on color dracula " Leader let mapleader = " " set backspace=2 " Backspace deletes like most programs in insert mode set nobackup set nowritebackup set noswapfile " http://robots.thoughtbot.com/post/18739402579/global-gitignore#comment-458413287 set history=50 set ruler " show the cursor position all the time set showcmd " display incomplete commands set incsearch " do incremental searching set laststatus=2 " Always display the status line set autowrite " Automatically :write before running commands " When the type of shell script is /bin/sh, assume a POSIX-compatible " shell for syntax highlighting purposes. let g:is_posix = 1 " Softtabs, 2 spaces set tabstop=2 set shiftwidth=2 set shiftround set expandtab " Display extra whitespace set list listchars=tab:»·,trail:·,nbsp:· " Use one space, not two, after punctuation. set nojoinspaces " Make it obvious where 80 characters is set textwidth=80 set colorcolumn=+1 " Numbers set relativenumber set numberwidth=5 " Open new split panes to right and bottom, which feels more natural set splitbelow set splitright " Quicker window movement nnoremap j nnoremap k nnoremap h nnoremap l " Always use vertical diffs set diffopt+=vertical " copy to buffer vmap :w! ~/.vimbuffer nmap :.w! ~/.vimbuffer " paste from buffer nmap :r ~/.vimbuffer " persistent undos set undofile set undodir=~/.vim/undodir " Keep all vim-related temp files in a single directory let $TMPDIR = '/tmp/vim-' . $USER silent! call mkdir($TMPDIR, '', 0700) " Switch syntax highlighting on, when the terminal has colors " Also switch on highlighting the last used search pattern. if (&t_Co > 2 || has("gui_running")) && !exists("syntax_on") syntax on endif filetype plugin indent on " Get off my lawn nnoremap :echoe "Use h boomer" nnoremap :echoe "Use l boomer" nnoremap :echoe "Use k boomer" nnoremap :echoe "Use j boomer" " junegunn/FZF set grepprg=rg\ --vimgrep\ --smart-case\ --follow command! -bang -nargs=* Rg call fzf#vim#grep("rg --column --line-number --no-heading --color=always --smart-case ".shellescape(), 1, {'options': '--delimiter : --nth 4..'}, 0) set rtp+=~/.fzf nnoremap :Files nnoremap :Rg " neoclide/coc " GoTo code navigation. nmap gd (coc-definition) nmap gy (coc-type-definition) nmap gi (coc-implementation) nmap gr (coc-references)