set background=dark let base16colorspace=256 " Access colors present in 256 colorspace set relativenumber set number set hlsearch se si se incsearch se expandtab se ts=4 sw=4 filetype plugin on se t_Co=256 se mouse=a se cursorline se cursorcolumn se ignorecase set encoding=utf-8 set guifont=Hurmit\ Nerd\ Font\ Mono\ Medium\ 12 " Theme "colorscheme monokai-tatooka colorscheme dracula " Vundle set nocompatible " required filetype off " required " set the runtime path to include Vundle and initialize set rtp+=~/.vim/bundle/Vundle.vim call vundle#begin() " alternatively, pass a path where Vundle should install plugins "call vundle#begin('~/some/path/here') " let Vundle manage Vundle, required Plugin 'gmarik/Vundle.vim' " Add all your plugins here (note older versions of Vundle used Bundle instead of Plugin) Plugin 'tpope/vim-fugitive' "Plugin 'christoomey/vim-conflicted' Plugin 'scrooloose/nerdtree' Plugin 'Xuyuanp/nerdtree-git-plugin' Bundle 'jistr/vim-nerdtree-tabs' Plugin 'vim-airline/vim-airline' Plugin 'vim-airline/vim-airline-themes' Plugin 'vim-scripts/indentpython.vim' Plugin 'raimondi/delimitmate' "Plugin 'scrooloose/syntastic' "syntax checker Plugin 'w0rp/ale' " async syntax checker "Plugin 'nvie/vim-flake8' Plugin 'majutsushi/tagbar' Plugin 'ctrlpvim/ctrlp.vim' Plugin 'airblade/vim-gitgutter' Plugin 'ryanoasis/vim-devicons' Plugin 'ivalkeen/vim-ctrlp-tjump' "Plugin 'tiagofumo/vim-nerdtree-syntax-highlight' Plugin 'fisadev/vim-isort' Plugin 'junegunn/fzf.vim' "Plugin 'valloric/youcompleteme' Plugin 'ervandew/supertab' Plugin 'davidhalter/jedi-vim' Plugin 'shougo/deoplete.nvim' Plugin 'zchee/deoplete-jedi' Plugin 'mustache/vim-mustache-handlebars' Plugin 'xolox/vim-misc' Plugin 'xolox/vim-session' " All of your Plugins must be added before the following line call vundle#end() " required filetype plugin indent on " required " Powerline set rtp+=/usr/share/powerline/bindings/vim/ " Always show statusline set laststatus=2 " vim-airline "let g:airline_theme='hybridline' let g:airline_theme='dracula' let g:airline_powerline_fonts = 1 let g:airline#extensions#tabline#enabled = 1 let g:airline#extensions#branch#displayed_head_limit = 10 " pretty code let python_highlight_all=1 syntax on " YouCompleteMe "let g:ycm_python_binary_path = '/usr/bin/python3' let g:ycm_collect_identifiers_from_tags_files = 1 " Let YCM read tags from Ctags file let g:ycm_use_ultisnips_completer = 0 " Default 1, just ensure let g:ycm_seed_identifiers_with_syntax = 1 " Completion for programming language's keyword let g:ycm_complete_in_comments = 1 " Completion in comments let g:ycm_complete_in_strings = 1 " Completion in string " NerdTREE map :NERDTreeToggle autocmd vimenter * NERDTree | wincmd l " open NerdTree when entering vim, then focus right window autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif let g:nerdtree_tabs_open_on_console_startup=0 let g:nerdtree_tabs_open_on_new_tab=0 let NERDTreeMinimalUI=1 let NERDTreeDirArrows=0 let NERDTreeIgnore=['\.pyc$', '\~$', '^__pycache__$'] "ignore files in NERDTree let g:NERDTreeWinSize = 25 " find current file in NERDTree by pressing ALT+V (√ in osx) nnoremap √ :NERDTreeFind let g:WebDevIconsNerdTreeAfterGlyphPadding = '' let g:webdevicons_conceal_nerdtree_brackets = 1 let g:WebDevIconsNerdTreeGitPluginForceVAlign = 0 let g:WebDevIconsUnicodeGlyphDoubleWidth = 0 " NERDTree highlight let g:NERDTreeFileExtensionHighlightFullName = 1 let g:NERDTreeExactMatchHighlightFullName = 1 let g:NERDTreePatternMatchHighlightFullName = 1 " uncommon file extensions highlightling: let g:NERDTreeLimitedSyntax = 1 " uncomment these 3 lines to disable completely: " let g:NERDTreeDisableFileExtensionHighlight = 1 " let g:NERDTreeDisableExactMatchHighlight = 1 " let g:NERDTreeDisablePatternMatchHighlight = 1 " Tagbar nmap :TagbarToggle " Filetype autocmd au FileType *.py \ setlocal tabstop=4 softtabstop=4 shiftwidth=4 textwidth=119 expandtab autoindent fileformat=unix au FileType *.js, *.html, *.css \ setlocal tabstop=2 \| setlocal softtabstop=2 \| setlocal shiftwidth=2 au FileType *.hbs \ setlocal tabstop=2 \| setlocal softtabstop=2 \| setlocal shiftwidth=2 \| setlocal ft=smarty " Paste Toggle " nmap :se paste! " CtrlP Search let g:ctrlp_map = '' let g:ctrlp_cmd = 'CtrlP' set wildignore+=*/tmp/*,*.so,*.swp,*.zip,*.pyc " Ignore some folders and files for CtrlP indexing let g:ctrlp_custom_ignore = { \ 'dir': '\.git$\|\.yardoc\|public$|log\|tmp$', \ 'file': '\.so$\|\.dat$|\.DS_Store$' \ } " Use ag for ctrlp searching let g:ctrlp_user_command = 'ag %s -i --nocolor --nogroup --hidden \ --ignore .git \ --ignore .svn \ --ignore .hg \ --ignore .DS_Store \ --ignore "**/*.pyc" \ -g ""' " CtrlP Tag Jump " (π is ALT+P in osx) nnoremap π :CtrlPtjump vnoremap π :CtrlPtjumpVisual let g:ctrlp_tjump_only_silent = 0 " Go to last active tab au TabLeave * let g:lasttab = tabpagenr() nnoremap :exe "tabn ".g:lasttab vnoremap :exe "tabn ".g:lasttab " Move between tabs with ALT-J (¶) and ALT-K (§) nnoremap ¶ :tabprevious nnoremap § :tabnext " ALT-T creates a new empty tab nnoremap † :tabnew " NeoVim only: Alt-arrows to move between tabs nnoremap :tabprevious nnoremap :tabnext " CTags set tags=~/work/shippo/.tags " vimpy import resolver let g:vimpy_prompt_resolve = 1 let g:vimpy_remove_unused = 1 " FZF fuzzy search for vim set rtp+=/usr/local/opt/fzf let g:fzf_layout = { 'down': '~50%' } " Ctrl-K brings up file search (fzf) nnoremap :Files " Ctrl-L brings up text search (uses ag) nnoremap :Ag " Ctrl-F brings up current word text search (using ag) nnoremap :Ag " preview window (press to toggle) command! -bang -nargs=* Ag \ call fzf#vim#ag(, \ 0 ? fzf#vim#with_preview('up:60%') \ : fzf#vim#with_preview('right:50%:hidden', '?'), \ 0) "setglobal complete-=i "set include=^\\s*#\\s*include\ \\(ø :tab split :call jedi#goto() nnoremap d :tab split :call jedi#goto() let g:jedi#force_py_version = 3 " Ale let g:airline#extensions#ale#enabled = 1 let g:ale_sign_error = '' let g:ale_sign_warning = '' highlight ALEErrorSign guifg=#CC3333 ctermbg=160 highlight ALEWarningSign guifg=#FF9900 ctermbg=136 let g:ale_echo_msg_error_str = '' let g:ale_echo_msg_warning_str = '' let g:ale_echo_msg_format = '%severity% [%linter%] %s' "highlight AleWarning guifg=#FF9900 gui=bold,underline "highlight AleWarningLine guibg=NONE gui=italic "highlight AleError guifg=#FF3333 gui=bold,underline "highlight AleErrorLine guibg=NONE gui=italic let g:ale_lint_delay = 1000 " 1 sec delay to run linter after text is changed let g:ale_completion_enabled = 1 " Syntastic let g:syntastic_python_checkers = ['pylint', 'flake8'] let g:syntastic_python_pylint_post_args="--max-line-length=120 --disable=C0111" " Deoplete let g:deoplete#enable_at_startup = 1 " SuperTab let g:SuperTabDefaultCompletionType = "" " Fugitive set diffopt+=vertical " Do not Load rope plugin (should make jedi-vim faster) let g:pymode_rope = 0 " highlight non-ascii syntax match nonascii "[^\x00-\x7F]" highlight nonascii guibg=Red ctermbg=2 " set yank to osx's clipboard set clipboard=unnamed " use xmllint on Visual Selection by calling :XmlLint (remove '<,'> from command line first) command XmlLint '<,'>!xmllint --format - " True colors for NVIM if has('nvim') || has('termguicolors') set termguicolors endif " remove character from VertSplit column :set fillchars+=vert:\ " GitGutter let g:gitgutter_sign_added = '' "    let g:gitgutter_sign_modified = '' "       let g:gitgutter_sign_removed = '' "     let g:gitgutter_sign_removed_first_line = '' let g:gitgutter_sign_modified_removed = '' " Highlight all occurrences of word under cursor autocmd CursorMoved * exe exists("HlUnderCursor")?HlUnderCursor?printf('match Pmenu /\V\<%s\>/', escape(expand(''), '/\')):'match none':"" let HlUnderCursor=1 " toggle this to 0 to disable " Session let g:session_autoload = 'no' let g:session_autosave = 'no'