Last active
July 7, 2020 06:05
-
-
Save elijahmanor/7c2be125549cc49b4f8424b89d0267ca to your computer and use it in GitHub Desktop.
.vimrc
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
filetype off " required | |
set rtp+=~/.vim/bundle/Vundle.vim | |
call vundle#begin() | |
Plugin 'VundleVim/Vundle.vim' | |
Plugin 'tpope/vim-sensible' | |
Plugin 'scrooloose/nerdtree' | |
Plugin 'pangloss/vim-javascript' | |
Plugin 'MaxMEllon/vim-jsx-pretty' | |
" Plugin 'mxw/vim-jsx' | |
" Plugin 'neoclide/vim-jsx-improve' | |
Plugin 'ctrlpvim/ctrlp.vim' | |
Plugin 'tpope/vim-commentary' | |
Plugin 'tpope/vim-sleuth' | |
Plugin 'editorconfig/editorconfig-vim' | |
Plugin 'sickill/vim-monokai' | |
Plugin 'mhinz/vim-startify' | |
Plugin 'ervandew/supertab' | |
Plugin 'vim-airline/vim-airline' | |
Plugin 'vim-airline/vim-airline-themes' | |
Plugin 'tpope/vim-unimpaired' | |
Plugin 'mileszs/ack.vim' | |
Plugin 'w0rp/ale' | |
Plugin 'wincent/terminus' " cursor/mouse/focus | |
Plugin 'vim-gitgutter' | |
Plugin 'wesQ3/vim-windowswap' " <Leader>ww | |
Plugin 'easymotion/vim-easymotion' | |
Plugin 'styled-components/vim-styled-components' | |
Plugin 'lifepillar/vim-cheat40' " <Leader>? | |
call vundle#end() " required | |
filetype plugin indent on " required | |
" see :h vundle for more details or wiki for FAQ | |
" Custom .vimrc Configuration | |
:let mapleader = "," | |
" Font | |
:set guifont=Source\ Code\ Pro\ for\ Powerline:h20 | |
colorscheme monokai | |
set number " Show line numbers | |
set ruler " Show line and column number | |
syntax enable " Turn on syntax highlighting allowing local overrides | |
set hlsearch " Highlight search matches | |
" Press Space to turn off highlighting and clear any message already displayed. | |
:nnoremap <silent> <Space> :nohlsearch<Bar>:echo<CR> | |
set foldmethod=syntax "syntax highlightning items specify folds | |
" set foldcolumn=1 "defines 1 col at window left, to indicate folding | |
let javaScript_fold=1 "activate folding by JS syntax | |
set foldlevelstart=99 "start file with all folds opened | |
" Zoom In | |
noremap Zz <c-w>_ \| <c-w>\| | |
" Zoom Out | |
noremap Zo <c-w>= | |
" Easier Split Navigations | |
nnoremap <C-J> <C-W><C-J> | |
nnoremap <C-K> <C-W><C-K> | |
nnoremap <C-L> <C-W><C-L> | |
nnoremap <C-H> <C-W><C-H> | |
" scrooloose/nerdtree | |
map <Leader>n :NERDTreeToggle<CR> | |
let NERDTreeShowHidden=1 | |
" open automatically when starts | |
autocmd StdinReadPre * let s:std_in=1 | |
autocmd VimEnter * if argc() == 1 && isdirectory(argv()[0]) && !exists("s:std_in") | exe 'NERDTree' argv()[0] | wincmd p | ene | endif | |
" Exit Vim when the only window left is NERDTree | |
autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif | |
" tpope/vim-commentary | |
" toggle commenting of lines with ,+/ | |
nmap <Leader>/ :Commentary<CR> | |
vmap <Leader>/ :Commentary<CR> | |
" vim-airline/vim-airline | |
let g:airline_powerline_fonts = 1 | |
let g:airline#extensions#tabline#enabled = 1 | |
let g:airline#extensions#tabline#fnamemod = ':t' | |
" ctrlpvim/ctrlp.vim | |
" ignore .gitignore | |
let g:ctrlp_user_command = ['.git/', 'git --git-dir=%s/.git ls-files -oc --exclude-standard'] | |
let g:ctrlp_show_hidden = 1 | |
" mileszs/ack.vim | |
" map Shift + F to Ack.vim | |
nmap <S-F> :Ack<space> | |
" use ag (the silver searcher) with ack (ignore .gitignore) | |
if executable('ag') | |
let g:ackprg = 'ag --vimgrep' | |
endif | |
" w0rp/ale | |
" let b:ale_fixers = {'javascript': ['prettier', 'eslint']} | |
let b:ale_fixers = {'javascript': ['eslint']} | |
let g:ale_fix_on_save = 1 | |
let g:ale_sign_error = '●' " Less aggressive than the default '>>' | |
let g:ale_sign_warning = '.' | |
" easymotion/vim-easymotion | |
" Jump to anywhere you want with minimal keystrokes, with just one key binding. | |
" <Leader><Leader> s{char}{char} to move to {char}{char} | |
nmap s <Plug>(easymotion-overwin-f2) | |
" show hidden characters | |
:set list | |
set listchars=tab:▸\ ,eol:¬ | |
" :set listchars=tab:→\ ,space:·,nbsp:␣,trail:•,eol:¶,precedes:«,extends:» | |
highlight NonText guifg=#4a4a59 | |
highlight SpecialKey guifg=#4a4a59 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment