-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvimrc
More file actions
186 lines (139 loc) · 4.2 KB
/
vimrc
File metadata and controls
186 lines (139 loc) · 4.2 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
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
"=========================================================================="
"
" Description: My personal vimrc. I am in the process of cleaning it up.
"
" Author: T.Wright <spartas AT gmail DOT com>
"
" Last Change: 2009.07.23
"
" Version: 0.015
"
" Usage: I am unable to provide content from my sources directory.
" See line 46.
"=========================================================================="
" ============
" Nice buffers
" ============
map <F7> :b# <CR>
" ====== === =============== === ===== ====
" VimTip for editing/loading teh vimrc file
" ====== === =============== === ===== ====
nmap ,s :source $MYVIMRC
nmap ,v :e $MYVIMRC
" =====================
" Dis/Enable Paste Mode
" =====================
"map <S-F11> :call Paste_on_off()<CR>
set pastetoggle=<S-F11>
let paste_mode = 0 " 0 = normal, 1 = paste
set visualbell
set cul
set modeline
set nocompatible
" ===
" PDV
" ===
so ~/.vim/plugin/supertab.vim
" Include various helper files [Commented]
" (This includes things I am unable to provide for intelluctual
" property, copyright, and/or personal reasons)
"ru! ~/.vim/sources/*.vim
" ===========================
" The paste switcher function
" ===========================
"func! Paste_on_off()
" if g:paste_mode == 0
" set paste
" let g:paste_mode = 1
" else
" set nopaste
" let g:paste_mode = 0
" endif
" return
"endfunc
" =======================================
" Dark background to match your dark soul
" =======================================
set bg=dark
" ===================================
" Smart options for those who program
" ====================================
set smarttab
set noexpandtab
set tabstop=2
set shiftwidth=2
set autoindent
set smartindent
set cindent
"filetype plugin indent on
set fmr={,}
set linespace=1 " Display additional space between lines for easier readability
set fo=tcrqn
set ignorecase
set smartcase
" =============================================
" Syntax highlighting and incremental searching
" =============================================
syn on
set incsearch
" ======================================
" Do syntax highlight syncing from start
" ======================================
autocmd BufEnter * :syntax sync fromstart
" ===========================
" Always show the status line
" ===========================
set ruler
" ============================
" Format with Q in visual mode
" ============================
nnoremap Q gq
" Remap ctrl-space to omnicompletion
" Thx mattikus
inoremap <C-space> <C-x><C-o>
map <F10> :new<CR>:read !svn diff<CR>:set syntax=diff buftype=nofile<CR>gg
set notr
" ============
" PHP Checking
" ============
:set autowrite " Enabled, so files are automatically saved before syntax checking is performed
:set makeprg=php\ -l\ %
:set errorformat=%m\ in\ %f\ on\ line\ %l
" taglist plugin settings
"let Tlist_Inc_Winwidth = 0
let tlist_php_settings = 'php;c:class;f:function'
noremap <silent> <F8> :TlistToggle<CR>
set mousehide
" ==========
" 256 Colors
" ==========
set t_Co=256
" =======================
" Hide un-necessary files
" =======================
let g:explHideFiles='^\.svn,\.$'
" No help, plz
nmap <F1> <Esc>
map <F10> :new<CR>:read !svn diff<CR>:set syntax=diff buftype=nofile<CR>gg
set notr
if version > 700
set autochdir "Magic
endif
"let g:SuperTabDefaultCompletionType = "<C-X><C-O>"
" HTML generation
let html_use_css = 1
let use_xhtml = 1
" Highlighted groups
:hi Commented_CSS ctermbg=darkgreen guibg=darkgreen
" Highlighting matches
:match Commented_CSS /\/\*\s*\(\w\|-\)*\s*:\s\(\w\|\s\)*;\?\*\//
:match Commented_CSS /\/\*\s*\(\w\|-\)*\s*:\s\(\w\|\s\)*;\?\s*\*\//
" Pretty print SQL
map ,sql <ESC>:s/\(from\<Bar>where\<Bar>select\<Bar>left join\)/<C-V><CR>\U\1/g
vmap ,sql <ESC>:'<,'>s/\(from\<Bar>where\<Bar>select\<Bar>left join\)/\U\1/g
" Nifty abbreviations
iab AlP ABCDEFGHIJKLMNOPQRSTUVWXYZ
iab MoN January February March April May June July August September October November December
iab MoO Jan Feb Mar Apr May Jun Jul Aug Sep Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec
iab NuM 12345678901234567890123456789012345678901234567890123456789012345678901234567890
iab RuL -----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2