-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdot_vimrc
51 lines (41 loc) · 1.35 KB
/
dot_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
set nocompatible " no vi compatible syntax
syntax enable
let mapleader = "\<Space>" " Set space as leader
set clipboard=unnamedplus " for x11
"set clipboard=unnamed " for win 10
set expandtab " insert spaces when tab is pressed
set tabstop=4 softtabstop=4 " number of spaces inserted when tab key pressed
set shiftwidth=4 " number of spaces inserted by < & > indent motions
set smartindent " try to indent
set number " number lines
set relativenumber " relative number lines
set incsearch " incremental search
set cursorline " highlight current line
set lazyredraw " redraw only when we need to.
set scrolloff=5 " show lines above and below cursor (when possible)
set timeout timeoutlen=1000 ttimeoutlen=100 " fix slow O inserts
set hidden " allow buffer to be hiden if modified
set splitbelow
set noswapfile
set nobackup
set splitright
" smart case sensitive search
set smartcase
set ignorecase
" undo persist
set undodir=~/.vim/undodir
set undofile
" Highlight search toggle
set hlsearch
set colorcolumn=90
highlight ColorColumn ctermbg=black
filetype indent on " load filetype-specific indent files
" Display all matching files when we tab complete in command mode
set wildmenu
set wildmode=list:full
set wildcharm=<C-Z>
map ; :
nnoremap <C-J> :bp <CR>
nnoremap <C-K> :bn <CR>
noremap <leader>f <C-W>w
nnoremap <leader>\ :nohlsearch<CR> " Disable until next search