-
Notifications
You must be signed in to change notification settings - Fork 0
/
vimrc
74 lines (64 loc) · 1.73 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
" Author: Robert Newbould <[email protected]>
" Source: https://github.com/c0nspiracy/dotfiles
" Load pathogen {{{
call pathogen#infect()
" }}}
" Basic configuration {{{
syntax on
filetype plugin indent on
set nocompatible
" Allow backgrounding buffers without writing them,
" and remember marks/undo for backgrounded buffers
set hidden
" Allow backspacing over everything in insert mode
set backspace=indent,eol,start
set encoding=utf-8
set termencoding=utf-8
" Store temporary files in a central location
set backupdir=~/.vim-tmp,~/.tmp,~/tmp,/var/tmp,/tmp
set directory=~/.vim-tmp,~/.tmp,~/tmp,/var/tmp,/tmp
set ignorecase
set smartcase
set title
" Define , as map leader {{{
let mapleader = ','
" }}}
" Wild menu {{{
set wildmenu
set wildmode=list:longest
" }}}
set visualbell
" }}}
" UI Options {{{
set list listchars=trail:·,extends:>,tab:»·
set laststatus=2
set incsearch
set hlsearch
set number
set ruler
set scrolloff=3
set showcmd
set showmode
set history=1000
" }}}
" Layout / Text formatting {{{
set autoindent
set wrap
set textwidth=78
set shiftwidth=4
set tabstop=4
set softtabstop=4
set expandtab
" }}}
set showmatch
set t_Co=256
set background=dark
colorscheme distinguished
let g:Powerline_symbols = 'fancy'
" Removes trailing spaces
function TrimWhiteSpace()
%s/\s*$//
''
:endfunction
map <F2> :call TrimWhiteSpace()<CR>
map! <F2> :call TrimWhiteSpace()<CR>