-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvimmerc
57 lines (53 loc) · 1.54 KB
/
vimmerc
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
" Colors {{{
set t_Co=256 " enable 256 colors
colorscheme apprentice " set the colorscheme
set background=dark " set the background to dark
syntax enable " enable syntax highlighting
" }}}
" UI Layout {{{
set number " show line numbers on left
set showcmd " show commands at bottom
set cursorline " highlight current line
set laststatus=2 " always show status line
set ruler " show position of cursor
set list " show whitespace characters
set showmatch " highlight matching braces
set mouse=a " enable mouse in all modes
" set how whitespace is displayed
set listchars=tab:,.,trail:.,extends:#,nbsp:.
" }}}
" Spaces and Tabs {{{
filetype indent on
set expandtab " expand tabs to spaces
set tabstop=4 " set tabs to 4 spaces
set softtabstop=4 " tab/backspace will insert/delete 4 spaces
set autoindent " set auto indenting
set shiftwidth=4 " set autoindent width
" }}}
" Searching {{{
set hlsearch " highlight search terms
set ignorecase " case insensitive search
set smartcase " case sensitive if any capitals
" }}}
" Folding {{{
set foldenable " enable folding
set foldlevelstart=10 " open most folds by default
set foldnestmax=10 " 10 nested fold max
set foldmethod=syntax " fold on syntaC
" }}}
" Modelines {{{
set modeline
set modelines=1
" }}}
" Keybindings {{{
vnoremap <C-c> "+y
nnoremap <space> za
imap jj <Esc>
" }}}
" Autogroups {{{
augroup config
autocmd BufWritePre * :%s/\s\+$//e
autocmd FileType python setlocal foldmethod=indent
augroup END
" }}}
" vim:foldmethod=marker:foldlevel=0