-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path.vimrc
94 lines (78 loc) · 2.32 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
syntax on
" indentation related and coding style
set tabstop=2 " The width of a TAB is set to 2.
set expandtab " Expand TABs to spaces
set softtabstop=2
set shiftwidth=2 " when indenting with '>', use 2 spaces width
set autoindent
" display related stuff
set relativenumber
set number
colorscheme wombat256mod
set foldenable
set colorcolumn=80
set cursorline
" search related
set hlsearch
set ignorecase
set smartcase
set incsearch
" misc
set hidden " Hide buffers when they are abandoned
set wildmenu
set showcmd " Show (partial) command in status line.
set showmatch " Show matching brackets.
set shell=/bin/bash
set nocompatible " be iMproved, required
filetype off " required
set tags=./tags;/ " search for tags in pwd and go up until found
map <A-]> :vsp <CR>:exec("tag ".expand("<cword>"))<CR> " open tag in vsplit
" set the runtime path to include Vundle and initialize
if has('win32') || has('win64')
set runtimepath+=$HOME/vimfiles/bundle/Vundle.vim
else
set runtimepath+=~/.vim/bundle/Vundle.vim
endif
call vundle#begin()
" let Vundle manage Vundle, required
Plugin 'gmarik/Vundle.vim'
Plugin 'kien/ctrlp.vim'
Plugin 'bling/vim-airline'
Plugin 'vim-syntastic/syntastic'
Plugin 'airblade/vim-gitgutter'
Plugin 'tpope/vim-fugitive'
" Plugin 'rust-lang/rust.vim'
" Plugin 'neoclide/coc.nvim'
" Plugin 'Valloric/YouCompleteMe'
" Plugin 'jelera/vim-javascript-syntax'
" Plugin 'mileszs/ack.vim'
" Plugin 'gkz/vim-ls'
" Plugin 'dracula/vim'
call vundle#end() " required
filetype plugin indent on " required
set laststatus=2
if has('win32') || has('win64')
set guifont=Consolas:h11
endif
set t_Co=256
set guioptions-=r
set guioptions-=R
set guioptions-=l
set guioptions-=L
" syntastic settings
set statusline+=%#warningmsg#
set statusline+=%{SyntasticStatuslineFlag()}
set statusline+=%*
let g:syntastic_always_populate_loc_list = 1
let g:syntastic_auto_loc_list = 1
let g:syntastic_check_on_open = 1
let g:syntastic_check_on_wq = 0
" Airline settings
let g:airline#extensions#tabline#enabled = 1
let g:airline#extensions#tabline#formatter = 'default'
" let g:rustfmt_autosave = 1
let mapleader = ","
" custom mapping
command Fo execute "normal! $zf%" " fold line by doing a :Fo
nnoremap <leader><tab> :tabn<cr>
nnoremap <leader>n :noh<cr>