-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.vimrc
More file actions
94 lines (75 loc) · 1.68 KB
/
Copy path.vimrc
File metadata and controls
94 lines (75 loc) · 1.68 KB
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
" Plugin management
" -----------------
" Vundle setup.
set nocompatible
filetype off
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" Vundle bundles.
Bundle 'tpope/vim-surround'
Plugin '29decibel/codeschool-vim-theme'
Plugin 'altercation/vim-colors-solarized'
Plugin 'bronson/vim-trailing-whitespace'
Plugin 'ciaranm/inkpot'
Plugin 'dsolstad/vim-wombat256i'
Plugin 'gmarik/vundle'
Plugin 'kien/ctrlp.vim'
Plugin 'morhetz/gruvbox'
Plugin 'nanotech/jellybeans.vim'
Plugin 'pikma/space-macro'
Plugin 'rking/ag.vim'
Plugin 'scrooloose/syntastic'
Plugin 'tpope/vim-fugitive'
Plugin 'tpope/vim-pathogen'
Plugin 'w0ng/vim-hybrid'
call vundle#end()
filetype plugin indent on
" Basics
" ------
" Show line numbers.
set number
" Disable beeps.
set visualbell
" Change leader key to , (comma).
let mapleader = ","
" Vimrc
" -----
" Easy shortcut for editing vimrc.
" nmap <leader>r :tabedit $MYVIMRC<CR>
" Source the vimrc file after saving it
if has("autocmd") && !exists("autocmd_vimrc")
let autocmd_vimrc = 1
autocmd bufwritepost ~/.vimrc source $MYVIMRC
endif
" Indentation
" -----------
set expandtab
set tabstop=4
set shiftwidth=4
set softtabstop=4
set autoindent
" Show 80 char limit.
set textwidth=80
set colorcolumn=+1
" Search
" ------
set ignorecase
set smartcase
set incsearch
set hlsearch
" Ctrl-n to turn off current search.
map <C-n> :nohlsearch<CR>
" Colors
" ------
syntax on
set background=dark
set t_Co=256
colorscheme gruvbox
" Quickfix
" --------
" Fix position.
:autocmd FileType qf wincmd J
" Few shortcuts for working with LaTeX files.
" -------------------------------------------
nnoremap <leader>c :!pdflatex -output-directory=%:p:h %<CR>
nnoremap <leader>v :!open %:r.pdf<CR>