-
Notifications
You must be signed in to change notification settings - Fork 0
/
.vimrc
97 lines (79 loc) · 2.23 KB
/
.vimrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
" Bundle Plugin Manager Setup"
set nocompatible " be iMproved, required
filetype off " required
" Backspace Magic"
set backspace=indent,eol,start
" 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 'VundleVim/Vundle.vim'
Plugin 'tpope/vim-fugitive'
Plugin 'rstacruz/sparkup', {'rtp': 'vim/'}
"Auto complete engine"
Plugin 'ycm-core/YouCompleteMe'
call vundle#end() " required
filetype plugin indent on " required
"indentation settings
set expandtab
set tabstop=4
set shiftwidth=4
"themeing and number line
set relativenumber
syntax enable
"autocompletion engine
packloadall
call plug#begin()
"File manager"
Plug 'preservim/nerdtree'
"Dracula Themes"
Plug 'sainnhe/sonokai'
"Airline bottom Bar"
Plug 'vim-airline/vim-airline'
Plug 'vim-airline/vim-airline-themes'
"Golang
Plug 'fatih/vim-go', { 'do': ':GoUpdateBinaries' }
Plug 'neoclide/coc.nvim', {'branch': 'release'}
" Run :PlugInstall to install the plugin.
call plug#end()
"file tree shortcuts
map <C-z> :NERDTreeToggle<CR><C-w>5<
let g:NERDTreeDirArrowExpandable = '▸'
let g:NERDTreeDirArrowCollapsible = '▾'
let NERDTreeShowHidden=1
"auto complete
let g:ycm_semantic_triggers = {
\ 'c': [ 're!\w{1}' ],
\ 'cpp': [ 're!\w{1}' ],
\ 'go': [ 're!\w{1}' ],
\ }
"auto term shortcut
nnoremap <C-t> :bel term<CR><C-w>10-
"go jump definition
nnoremap <C-j> :YcmCompleter GoToDefinition<CR>
"save
nnoremap <C-s> :w<CR>
" Important!!
if has('termguicolors')
set termguicolors
endif
colorscheme sonokai
" The configuration options should be placed before `colorscheme sonokai`.
let g:sonokai_style = 'andromeda'
let g:sonokai_better_performance = 1
let g:airline_theme = 'deus'
"shortcuts for tabs
set splitright
nnoremap <C-n> :tabnext<CR>
nnoremap <C-b> :tabprevious<CR>
"Vim motion in insert mode
inoremap <C-h> <Left>
inoremap <C-j> <Down>
inoremap <C-k> <Up>
inoremap <C-l> <Right>
cnoremap <C-h> <Left>
cnoremap <C-j> <Down>
cnoremap <C-k> <Up>
cnoremap <C-l> <Right>