This repository has been archived by the owner on Nov 7, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.vimrc
98 lines (90 loc) · 2.51 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
filetype indent on
set autoread
set autoindent
set backspace=indent,eol,start
set cursorline
set encoding=utf-8
set expandtab
set formatoptions=qrn1
set foldlevelstart=99
set foldmethod=indent
set gdefault
set guifont=Consolas\ 20
set hidden
set hlsearch
set ignorecase
set incsearch
set laststatus=2
set mouse=c
set number
set ruler
set shiftwidth=2
set softtabstop=2
set showmatch
set scrolloff=3
set showmode
set showcmd
set statusline=%<\ %n:%f\ %m%r%y%=%-35.(line:\ %l\ of\ %L,\ col:\ %c%V\ (%P)%)
set smartindent
set t_Co=256
set tabstop=4
set ttyfast
set wildignore+=*/tmp/*,*.so,*.swp,*.zip,*/node_modules/*
set wildmenu
set wildmode=list:longest
au BufNewFile,BufRead Dockerfile set filetype=sh
if &compatible
set nocompatible
endif
" Dein Plugin Setup & Config
" For some reason, these cannot be imported in nvim
" Add the dein installation directory into runtimepath
set runtimepath+=~/.cache/dein/repos/github.com/Shougo/dein.vim
if dein#load_state('~/.cache/dein')
call dein#begin('~/.cache/dein')
call dein#add('~/.cache/dein')
" vim 8+ or neovim autocomplete & fuzzy
call dein#add('Shougo/deoplete.nvim')
if !has('nvim')
call dein#add('roxma/nvim-yarp')
call dein#add('roxma/vim-hug-neovim-rpc')
endif
call dein#add('Shougo/denite.nvim')
" basic editor flair
call dein#add('airblade/vim-gitgutter')
call dein#add('arcticicestudio/nord-vim')
call dein#add('bling/vim-airline')
call dein#add('gregsexton/MatchTag')
call dein#add('kien/ctrlp.vim')
"" NOTE: fugitive slows down docker-based envs
call dein#add('tpope/vim-fugitive')
call dein#add('tpope/vim-surround')
call dein#add('Yggdroot/indentLine')
" Nerdtree
call dein#add('scrooloose/nerdtree')
call dein#end()
call dein#save_state()
endif
" imports of other things
source ~/.vimrcs/colors.vim
source ~/.vimrcs/denite.vim
source ~/.vimrcs/deoplete.vim
source ~/.vimrcs/nerdtree.vim
source ~/.vimrcs/shell-bindings.vim
" sweet-spot configuration to make sure that syntax + colors does not cause
" lag when moving around in the buffer
set regexpengine=1
syntax on
" key bindings
nmap <leader>s :/\<<C-r><C-w>\>/<CR>
nmap <leader>t :CtrlP<CR>
nmap <leader><tab> :NERDTreeToggle<CR>
nmap <leader><space> :noh <bar> e<CR>
nmap <leader>G :GitGutterLineHighlightsToggle<CR>
nmap <leader>g :<C-u>DeniteProjectDir grep<CR>
nmap <leader>o :<C-u>Denite outline<CR>
map <space>n :tabnext<CR>
map <space>b :tabprevious<CR>
map <space>o :tabe<space>
map <space>w :w<CR>
map <space>q :q<CR>