1 | set nocompatible |
2 | set t_RB= |
3 | set t_RF= |
4 | set t_u7= |
5 |
|
6 | au BufReadPost * if line("'\"") > 0 && line("'\"") <= line("$") |
7 | \| exe "normal! g'\"" | endif |
8 |
|
9 | " Formatting configuration |
10 | filetype plugin indent on |
11 | set spelllang=en_us |
12 | set encoding=utf-8 |
13 |
|
14 | " Keyboard mapping |
15 | let mapleader=" " |
16 | set clipboard=unnamedplus |
17 |
|
18 | inoremap jk <ESC> |
19 | noremap <leader>w ^ |
20 | noremap <leader>e $ |
21 | noremap <leader>f <c-w> |
22 | noremap <c-n> :tabnew<CR> |
23 | noremap <leader><CR>1 :b1<CR> |
24 | noremap <leader><CR>2 :b2<CR> |
25 | noremap <leader><CR>3 :b3<CR> |
26 | noremap <leader><CR>4 :b4<CR> |
27 | noremap <leader><CR>5 :b5<CR> |
28 | noremap <leader><CR>6 :b6<CR> |
29 | noremap <leader><CR>7 :b7<CR> |
30 | noremap <leader><CR>8 :b8<CR> |
31 | noremap <leader><CR>9 :b9<CR> |
32 | noremap <leader>t :ter<CR> |
33 | noremap <leader>r :so $MYVIMRC<CR> |
34 | noremap <leader>1 1gt |
35 | noremap <leader>2 2gt |
36 | noremap <leader>3 3gt |
37 | noremap <leader>4 4gt |
38 | noremap <leader>5 5gt |
39 | noremap <leader>6 6gt |
40 | noremap <leader>7 7gt |
41 | noremap <leader>8 8gt |
42 | noremap <leader>9 9gt |
43 |
|
44 | map <leader>n :NERDTreeToggle<CR> |
45 |
|
46 | " Vim style configuration |
47 | syntax on |
48 |
|
49 | set showcmd |
50 | set showmatch |
51 |
|
52 | set number |
53 | set numberwidth=4 |
54 |
|
55 | set tabstop=4 |
56 | set shiftwidth=4 |
57 | set smarttab |
58 | set expandtab |
59 |
|
60 | " Enable Plug plugins |
61 | call plug#begin(expand('<sfile>:p:h') . '/plugged') |
62 |
|
63 | Plug 'vim-airline/vim-airline' |
64 | Plug 'vim-airline/vim-airline-themes' |
65 | Plug 'sainnhe/sonokai' |
66 | Plug 'tribela/vim-transparent' |
67 | Plug 'tpope/vim-fugitive' |
68 | Plug 'scrooloose/nerdtree' |
69 | Plug 'ryanoasis/vim-devicons' "RMHEADLESS |
70 | Plug 'tiagofumo/vim-nerdtree-syntax-highlight' |
71 | Plug 'bling/vim-bufferline' |
72 | Plug 'airblade/vim-gitgutter' |
73 | Plug 'jiangmiao/auto-pairs' |
74 | Plug 'tpope/vim-surround' |
75 | Plug 'sheerun/vim-polyglot' |
76 | Plug 'ervandew/supertab' |
77 | Plug 'meatballs/vim-xonsh' |
78 | Plug 'valloric/matchtagalways' |
79 | Plug 'godlygeek/tabular' |
80 | Plug 'vim-syntastic/syntastic' |
81 |
|
82 | call plug#end() |
83 |
|
84 |
|
85 | " Automatically install any Plug plugins |
86 | autocmd VimEnter * |
87 | \ if len(filter(values(g:plugs), '!isdirectory(v:val.dir)')) |
88 | \| PlugInstall --sync |
89 | \| q |
90 | \| qa! |
91 | \| endif |
92 |
|
93 |
|
94 | if (has("termguicolors")) |
95 | set termguicolors |
96 | endif |
97 |
|
98 | autocmd ColorScheme * highlight! link SignColumn LineNr |
99 | autocmd ColorScheme * highlight Normal ctermbg=NONE guibg=NONE |
100 | autocmd ColorScheme * highlight NonText ctermbg=NONE guibg=NONE |
101 | autocmd ColorScheme * highlight VertSplit cterm=NONE ctermbg=NONE guibg=NONE |
102 | autocmd ColorScheme * highlight LineNr ctermbg=NONE guibg=NONE |
103 |
|
104 | let g:sonokai_style = 'atlantis' |
105 | let g:sonokai_better_performance = 1 |
106 |
|
107 | colorscheme sonokai |
108 |
|
109 | " Airline |
110 | set laststatus=2 |
111 | let g:airline_powerline_fonts=1 "RMHEADLESS |
112 | let g:airline_theme='sonokai' |
113 |
|
114 | " Git Gutter |
115 | let g:gitgutter_set_sign_backgrounds=1 |
116 | set updatetime=250 |
117 |
|
118 | " NERDTree |
119 | let NERDTreeShowHidden=1 |
120 |
|