-
Notifications
You must be signed in to change notification settings - Fork 0
/
vimrc
129 lines (102 loc) · 2.39 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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
source $VIMRUNTIME/defaults.vim
" Set compatibility
set nocompatible
" 256-colour display
set t_Co=256
" Performance
set ttyfast
set lazyredraw
" Set font
set guifont=FiraCode-Retina:h11
" Set background and colour scheme
" Dracula theme: https://github.com/dracula/vim
set background=light
colorscheme dracula
color dracula
let g:dracula_bold = 1
let g:dracula_italic = 1
let g:dracula_underline = 1
let g:dracula_undercurl = 1
let g:dracula_inverse = 1
let g:dracula_colorterm = 1
" Set UTF-8 encoding without BOM
set encoding=utf8 nobomb
set fileencoding=utf8 nobomb
" Automatically reload file on external change
set autoread
" Search ignore case except when putting capital letters
set ignorecase
set smartcase
" Search highlight and incremental
set hlsearch
set incsearch
" Display line numbers
" Line numbers column width
set number
set numberwidth=5
" Display cursor position
set ruler
" 80 characters
set textwidth=80
set colorcolumn=+1
" Enable backspace
set bs=indent,eol,start
" Add context line/column around cursor
" Free range cursor
set cursorline
set scrolloff=10
set sidescrolloff=5
set virtualedit=all
" Convert tabs to spaces
" Set shift amount
" Set amount of spaces of a tab
" Use smart tab
set expandtab
set shiftwidth=2
set shiftround
set tabstop=2
set softtabstop=2
set smarttab
" Use current line indent for new line
" Detect indentation of the current code
" Turn on indentation for file types
set autoindent
set smartindent
filetype indent on
" Enable syntax highlighting
syntax enable
filetype plugin on
" Show matching parenthesis, brackets
set showmatch
" Highlight special characters
" (tabs, traling spaces, end-of-line, non-breaking spaces)
set lcs=tab:▸\ ,trail:·,eol:¬,nbsp:_,space:·,extends:…,precedes:…
set list
highlight SpecialKey ctermfg=8 guifg=DimGrey
" Enable mouse
set mouse=a
" Set window splitting order
set splitright
set splitbelow
" File diff always displays vertically
set diffopt+=vertical
" ESC delays
set timeoutlen=1000
set ttimeoutlen=0
" Tab bar
" Suggestions
" Status bar
set showtabline=2
set wildmenu
set laststatus=2
set showcmd
" Swap files
set directory^=$HOME/.vim/tmp//
" Plugins
set runtimepath^=~/.vim/bundle/ctrlp.vim
set runtimepath^=~/.vim/bundle/emmet-vim
set runtimepath^=~/.vim/bundle/nerdtree
set runtimepath^=~/.vim/bundle/vim-airline
set runtimepath^=~/.vim/bundle/vim-wakatime
autocmd VimEnter * NERDTree
let NERDTreeShowHidden=1