Created
April 12, 2020 03:50
-
-
Save MatthewKosloski/e7abd75ac2e1584b3a5dd04c413f2172 to your computer and use it in GitHub Desktop.
My Vim Configuration
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" Automatically install vim-plug | |
if empty(glob('~/.vim/autoload/plug.vim')) | |
silent !curl -fLo ~/.vim/autoload/plug.vim --create-dirs | |
\ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim | |
autocmd VimEnter * PlugInstall --sync | source $MYVIMRC | |
endif | |
" Install plugins | |
call plug#begin() | |
Plug 'preservim/nerdtree' | |
Plug 'sheerun/vim-polyglot' | |
Plug 'joshdick/onedark.vim' | |
"Plug 'dracula/vim', {'as':'dracula'} | |
Plug 'vim-airline/vim-airline' | |
call plug#end() | |
" Colors | |
syntax on | |
colorscheme onedark | |
set background=dark | |
" UI Config | |
set number " show line numbers | |
set cursorline " highlight current line | |
set showmatch " hightlight matching [{()}] | |
set showcmd " show command in bottom bar | |
" Searching | |
set incsearch " search as characters are entered | |
set hlsearch " highlight matches | |
" Key maps | |
:let mapleader = "," " leader is comma | |
map <C-b> :NERDTreeToggle<CR> " Toggle Nerd Tree | |
nnoremap <leader><space> :nohlsearch<CR> " Turn off search highlight | |
" Change keys for navigating panes | |
nnoremap <leader>j <C-W><C-J> | |
nnoremap <leader>k <C-W><C-K> | |
nnoremap <leader>l <C-W><C-L> | |
nnoremap <leader>h <C-W><C-H> | |
" Plugin variables | |
let g:airline_symbols_ascii = 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment