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