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 1gt |
24 | noremap <leader><CR>2 2gt |
25 | noremap <leader><CR>3 3gt |
26 | noremap <leader><CR>4 4gt |
27 | noremap <leader><CR>5 5gt |
28 | noremap <leader><CR>6 6gt |
29 | noremap <leader><CR>7 7gt |
30 | noremap <leader><CR>8 8gt |
31 | noremap <leader><CR>9 9gt |
32 | noremap <leader>t :ter<CR> |
33 | noremap <leader>r :so $MYVIMRC<CR> |
34 | noremap <leader>1 :b1<CR> |
35 | noremap <leader>2 :b2<CR> |
36 | noremap <leader>3 :b3<CR> |
37 | noremap <leader>4 :b4<CR> |
38 | noremap <leader>5 :b5<CR> |
39 | noremap <leader>6 :b6<CR> |
40 | noremap <leader>7 :b7<CR> |
41 | noremap <leader>8 :b8<CR> |
42 | noremap <leader>9 :b9<CR> |
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 'meatballs/vim-xonsh' |
77 | Plug 'valloric/matchtagalways' |
78 | Plug 'godlygeek/tabular' |
79 |
|
80 | call plug#end() |
81 |
|
82 |
|
83 | " Automatically install any Plug plugins |
84 | autocmd VimEnter * |
85 | \ if len(filter(values(g:plugs), '!isdirectory(v:val.dir)')) |
86 | \| PlugInstall --sync |
87 | \| q |
88 | \| qa! |
89 | \| endif |
90 |
|
91 |
|
92 | if (has("termguicolors")) |
93 | set termguicolors |
94 | endif |
95 |
|
96 | autocmd ColorScheme * highlight! link SignColumn LineNr |
97 | autocmd ColorScheme * highlight Normal ctermbg=NONE guibg=NONE |
98 | autocmd ColorScheme * highlight NonText ctermbg=NONE guibg=NONE |
99 | autocmd ColorScheme * highlight VertSplit cterm=NONE ctermbg=NONE guibg=NONE |
100 | autocmd ColorScheme * highlight LineNr ctermbg=NONE guibg=NONE |
101 |
|
102 | let g:sonokai_style = 'atlantis' |
103 | let g:sonokai_better_performance = 1 |
104 |
|
105 | colorscheme sonokai |
106 |
|
107 | " Airline |
108 | set laststatus=2 |
109 | let g:airline_powerline_fonts=1 "RMHEADLESS |
110 | let g:airline_theme='sonokai' |
111 |
|
112 | " Git Gutter |
113 | let g:gitgutter_set_sign_backgrounds=1 |
114 | set updatetime=250 |
115 |
|
116 | " NERDTree |
117 | let NERDTreeShowHidden=1 |
118 |
|