Created
June 10, 2019 13:06
-
-
Save vinchi777/2ec6e0a2ac567405768b360abef3536d to your computer and use it in GitHub Desktop.
This file contains 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
set nocompatible " be iMproved, required | |
filetype off " required | |
call plug#begin('~/.vim/plugged') | |
" let Vundle manage Vundle, required | |
" Plug 'gmarik/Vundle.vim' | |
" Color schemes | |
Plug 'phanviet/vim-monokai-pro' | |
"Plug 'liuchengxu/space-vim-dark' | |
"Plug 'skreek/skeletor.vim' | |
"Plug 'dracula/vim' | |
"Plug 'morhetz/gruvbox' | |
"Plug 'SirVer/ultisnips' | |
Plug 'flazz/vim-colorschemes' | |
Plug 'honza/vim-snippets' | |
Plug 'tpope/vim-sensible' | |
Plug 'tpope/vim-surround' | |
Plug 'tpope/vim-fugitive' | |
Plug 'vim-ruby/vim-ruby' | |
Plug 'vim-airline/vim-airline' | |
Plug 'jiangmiao/auto-pairs' | |
Plug 'ctrlpvim/ctrlp.vim' | |
Plug 'mileszs/ack.vim' | |
Plug 'slim-template/vim-slim' | |
Plug 'terryma/vim-multiple-cursors' | |
Plug 'scrooloose/nerdcommenter' | |
Plug 'tpope/vim-ragtag' | |
Plug 'kchmck/vim-coffee-script' | |
Plug 'groenewege/vim-less' | |
Plug 'pangloss/vim-javascript' | |
Plug 'maxmellon/vim-jsx-pretty' | |
"Plug 'leafgarland/typescript-vim' | |
"Plug 'peitalin/vim-jsx-typescript' | |
Plug 'alvan/vim-closetag' | |
Plug 'w0rp/ale' | |
Plug 'neoclide/coc.nvim', {'tag': '*', 'do': { -> coc#util#install()}} | |
Plug 'scrooloose/nerdtree' | |
Plug 'tiagofumo/vim-nerdtree-syntax-highlight' | |
Plug 'ryanoasis/vim-devicons' | |
Plug 'mhinz/vim-signify' | |
"if has('nvim') | |
"Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' } | |
"Plug 'carlitux/deoplete-ternjs', { 'do': 'npm install -g tern' } | |
"else | |
"Plug 'Shougo/deoplete.nvim' | |
"Plug 'roxma/nvim-yarp' | |
"Plug 'roxma/vim-hug-neovim-rpc' | |
"endif | |
call plug#end() | |
"filetype plugin indent on " required | |
"set omnifunc=syntaxcomplete#Complete | |
" To ignore plugin indent changes, instead use: | |
"filetype plugin on | |
" | |
" Brief help | |
" :PluginList - lists configured plugins | |
" :PluginInstall - installs plugins; append `!` to update or just :PluginUpdate | |
" :PluginSearch foo - searches for foo; append `!` to refresh local cache | |
" :PluginClean - confirms removal of unused plugins; append `!` to auto-approve removal | |
" | |
" see :h vundle for more details or wiki for FAQ | |
" Put your non-Plugin stuff after this line | |
" map escape | |
imap jj <esc> | |
" resize windows | |
map <C-J> <C-W>j<C-W>_ | |
map <C-K> <C-W>k<C-W>_ | |
" tab navigation | |
map gr gT | |
" map paste toggle | |
set pastetoggle=<F2> | |
" show line numbers | |
set number | |
" trailing whitespace | |
set listchars=tab:\ \ ,trail:~,extends:> | |
set list | |
" map nerdtree toggle | |
nmap 9i :NERDTreeToggle<CR> | |
let g:WebDevIconsUnicodeDecorateFolderNodes = 1 | |
" no swapfile | |
set noswapfile | |
set t_Co=256 | |
" indent 2 spaces | |
set shiftwidth=2 | |
" map autocompletion | |
inoremap <Nul> <C-n> | |
" UltiSnips | |
"let g:UltiSnipsExpandTrigger="<tab>" | |
"let g:UltiSnipsJumpForwardTrigger="<c-j>" | |
"let g:UltiSnipsJumpBackwardTrigger="<c-k>" | |
" cltrP | |
" let g:ctrlp_working_path_mode = 2 | |
" Sane Ignore For ctrlp | |
let g:ctrlp_custom_ignore = { | |
\ 'dir': 'git$\|\.hg$\|\.svn$\|\.yardoc\|public\/images\|public\/system\|data\|log\|tmp\|node_modules$', | |
\ 'file': '\.exe$\|\.so$\|\.dat$' | |
\ } | |
" Us ag silver searcher | |
if executable('ag') | |
let g:ctrlp_user_command = 'ag %s -l --nocolor -g ""' | |
endif | |
"auto copy to clipboard | |
"set clipboard=unnamedplus | |
"remove trailing whitespace | |
nnoremap <silent> dt :let _s=@/<Bar>:%s/\s\+$//e<Bar>:let @/=_s<Bar>:nohl<CR> | |
"coffescript | |
let coffee_indent_keep_current = 1 | |
autocmd BufNewFile,BufReadPost *.coffee setl shiftwidth=2 expandtab | |
autocmd BufNewFile,BufReadPost *.html.erb setl shiftwidth=4 expandtab | |
" set filetypes as typescript.tsx | |
autocmd BufNewFile,BufRead *.tsx,*.jsx set filetype=typescript.tsx | |
"off syntastic for sass files | |
"let g:syntastic_mode_map = { 'passive_filetypes': ['sass', 'scss', 'slim', 'haml', 'less', 'ejs', 'html'] } | |
"for ejs syntax highlight | |
au BufNewFile,BufRead *.ejs set filetype=html | |
" deoplete | |
"let g:deoplete#sources#ternjs#tern_bin = '/usr/local/bin/tern' | |
"let g:deoplete#enable_at_startup = 1 | |
let g:closetag_filenames = '*.html,*.js' | |
let g:ale_completion_enabled = 0 "let COC do autocompletion | |
let g:ale_fixers = {'javascript': ['prettier', 'eslint']} | |
" COC | |
inoremap <expr> <TAB> pumvisible() ? "\<C-y>" : "\<C-g>u\<Tab>" | |
"autocmd! CompleteDone * if pumvisible() == 0 | pclose | endif | |
set signcolumn=yes | |
nmap <silent> gd <Plug>(coc-definition) | |
"set shortmess+=c | |
"set cmdheight=2 | |
let g:airline_section_error = '%{airline#util#wrap(airline#extensions#coc#get_error(),0)}' | |
let g:airline_section_warning = '%{airline#util#wrap(airline#extensions#coc#get_warning(),0)}' | |
"let g:airline_section_info = '%{airline#util#wrap(airline#extensions#coc#get_info(),0)}' | |
nmap <D-S-F> :Ack<space> | |
set termguicolors | |
"colorscheme dracula | |
colorscheme monokai_pro | |
"colorscheme skeletor | |
"colorscheme space-vim-dark | |
set expandtab |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment