git.fiddlerwoaroof.com
Browse code

moving

fiddlerwoaroof authored on 23/05/2016 18:37:18
Showing 1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,407 @@
1
+let counter = 0
2
+let g:syntastic_auto_loc_list=1
3
+let g:sql_type_default = 'pgsql'
4
+let g:airline_theme="murmur"
5
+let g:haddock_browser_callformat = "%s %s"
6
+let g:haddock_browser = "open"
7
+let g:lisp_rainbow=1
8
+"let g:pandoc_no_empty_implicits=1
9
+"let g:pandoc_use_hard_wraps = 1
10
+"let g:pandoc#modules#enabled =  ["formatting", "folding", "completion", "metadata","menu"]
11
+"let g:pandoc#modules#disabled =  ["command", "bibliographies"]
12
+"let g:pandoc_formatting_settings = "h"
13
+"let g:pandoc#filetypes#handled = ["markdown", "rst", "textile"]
14
+let g:snips_author="Edward Langley"
15
+let g:solarized_termtrans=1
16
+let g:syntastic_python_checkers = ['python']
17
+let g:Tex_CompileRule_pdf = 'xelatex -interaction=nonstopmode $*'
18
+let g:tex_flavor='xelatex'
19
+let g:unite_force_overwrite_statusline = 0
20
+let g:vimclojure#HighlightBuiltins = 1
21
+let g:vimclojure#HighlightBuiltins = 1
22
+let g:vimclojure#ParenRainbow = 1
23
+let g:vimclojure#ParenRainbow = 1
24
+let g:virtualenv_directory = "$HOME/python_envs"
25
+let g:phpcomplete_index_composer_command = "composer"
26
+let maplocalleader=','
27
+let $PAGER=''
28
+let python_highlight_all = 1
29
+let python_no_tab_space_error=1
30
+let python_space_errors=1
31
+let vimclojure#WantNailgun = 1
32
+let g:syntastic_scss_sass_args = "-r sass-css-importer -r susy"
33
+
34
+" This goes here in case a filetype overrides it
35
+
36
+"NeoBundle Scripts-----------------------------
37
+if has('vim_starting')
38
+  set nocompatible               " Be iMproved
39
+
40
+  " Required:
41
+  set runtimepath+=$HOME/.vim/bundle/neobundle.vim/
42
+endif
43
+
44
+" Required:
45
+call neobundle#begin(expand("$HOME/.vim/bundle"))
46
+
47
+" Let NeoBundle manage NeoBundle
48
+" Required:
49
+NeoBundleFetch 'Shougo/neobundle.vim'
50
+
51
+" My Bundles here:
52
+
53
+
54
+
55
+NeoBundle 'dbakker/vim-paragraph-motion'
56
+ NeoBundle 'jceb/vim-editqf'
57
+ NeoBundle 'mustache/vim-mustache-handlebars'
58
+ NeoBundle 'davidoc/taskpaper.vim'
59
+ NeoBundle 'altercation/vim-colors-solarized'
60
+ NeoBundle 'bitc/vim-hdevtools'
61
+ NeoBundle 'Blackrush/vim-gocode'
62
+ NeoBundle 'bling/vim-airline'
63
+ NeoBundle 'bling/vim-airline-themes'
64
+ NeoBundle 'burnettk/vim-angular'
65
+ NeoBundle 'christoomey/vim-tmux-navigator'
66
+ NeoBundle 'curist/vim-angular-template'
67
+ NeoBundle 'eagletmt/ghcmod-vim'
68
+ NeoBundle 'eagletmt/neco-ghc'
69
+ NeoBundle 'edsono/vim-matchit'
70
+ "NeoBundle 'enomsg/vim-haskellConcealPlus'
71
+ NeoBundle 'exu/pgsql.vim'
72
+ NeoBundle 'fiddlerwoaroof/htmljinja'
73
+ NeoBundle 'fiddlerwoaroof/vim-jinja'
74
+ NeoBundle 'godlygeek/tabular'
75
+ NeoBundle 'groenewege/vim-less'
76
+ NeoBundle 'guns/vim-clojure-static'
77
+ NeoBundle 'ivanov/vim-ipython'
78
+ NeoBundle 'jmcantrell/vim-virtualenv'
79
+ NeoBundle 'kien/rainbow_parentheses.vim'
80
+ NeoBundle 'kovisoft/slimv'
81
+ NeoBundle 'lukerandall/haskellmode-vim'
82
+ "NeoBundle 'm2mdas/phpcomplete-extended'
83
+ NeoBundle 'markcornick/vim-vagrant'
84
+ NeoBundle 'matthewsimo/angular-vim-snippets'
85
+ NeoBundle 'mattn/emmet-vim.git'
86
+ NeoBundle 'msanders/snipmate.vim'
87
+ NeoBundle 'othree/javascript-libraries-syntax.vim'
88
+ NeoBundle 'pangloss/vim-javascript'
89
+ NeoBundle 'raichoo/haskell-vim'
90
+ NeoBundle 'rking/ag.vim' "Ag search utility
91
+ NeoBundle 'rust-lang/rust.vim'
92
+ NeoBundle 'scrooloose/nerdcommenter'
93
+ NeoBundle 'scrooloose/nerdtree'
94
+ NeoBundle 'scrooloose/syntastic'
95
+ NeoBundle 'Shougo/unite.vim'
96
+ NeoBundle 'Shougo/unite-outline'
97
+ NeoBundle 'tsukkee/unite-tag'
98
+ NeoBundle 'Shougo/vimfiler.vim'
99
+ NeoBundle 'Shougo/vimproc'
100
+ NeoBundle 'Shougo/vimshell.vim'
101
+ NeoBundle 'sjl/gundo.vim'
102
+ NeoBundle 'sjl/vitality.vim'
103
+ NeoBundle 'sophacles/vim-bundle-mako'
104
+ NeoBundle 'terryma/vim-multiple-cursors'
105
+ NeoBundle 'tpope/vim-fireplace'
106
+ NeoBundle 'tpope/vim-fugitive'
107
+ NeoBundle 'tpope/vim-repeat'
108
+ NeoBundle 'tpope/vim-surround'
109
+ NeoBundle 'Twinside/vim-haskellFold'
110
+ NeoBundle 'Twinside/vim-hoogle'
111
+ "NeoBundle 'Valloric/YouCompleteMe'
112
+ "NeoBundle 'vim-pandoc/vim-pandoc'
113
+ NeoBundle 'vim-scripts/dbext.vim'
114
+ NeoBundle 'vim-scripts/php.vim--Garvin'
115
+ NeoBundle 'vim-scripts/pydoc.vim'
116
+ NeoBundle 'vim-scripts/VimClojure'
117
+ NeoBundle 'vim-voom/VOoM'
118
+ NeoBundle 'ytsunetsune/unite-outline-euslisp'
119
+ NeoBundle 'xolox/vim-misc'
120
+ NeoBundle 'xolox/vim-easytags'
121
+ NeoBundle 'majutsushi/tagbar'
122
+
123
+
124
+" Required:
125
+call neobundle#end()
126
+
127
+" Required:
128
+filetype plugin indent on
129
+
130
+" If there are uninstalled bundles found on startup,
131
+" this will conveniently prompt you to install them.
132
+NeoBundleCheck
133
+"End NeoBundle Scripts-------------------------
134
+
135
+let counter = 0
136
+let g:airline_theme="murmur"
137
+let g:haddock_browser_callformat = "%s %s"
138
+let g:haddock_browser = "open"
139
+let g:lisp_rainbow=1
140
+"let g:pandoc#filetypes#handled = ["markdown", "rst", "textile"]
141
+"let g:pandoc_formatting_settings = "h"
142
+"let g:pandoc#modules#disabled =  ["command", "bibliographies"]
143
+"let g:pandoc#modules#enabled =  ["formatting", "folding", "completion", "metadata","menu"]
144
+"let g:pandoc_no_empty_implicits=1
145
+"let g:pandoc_use_hard_wraps = 1
146
+let g:slimv_disable_clojure=1
147
+let g:slimv_repl_split=3
148
+let g:slimv_browser_command_suffix='2>&1 > /dev/null'
149
+let g:snips_author="Edward Langley"
150
+let g:solarized_termtrans=1
151
+let g:sql_type_default = 'pgsql'
152
+let g:syntastic_auto_loc_list=1
153
+let g:syntastic_python_checkers = ['python']
154
+let g:Tex_CompileRule_pdf = 'xelatex -interaction=nonstopmode $*'
155
+let g:tex_flavor='xelatex'
156
+let g:unite_force_overwrite_statusline = 0
157
+let g:vimclojure#HighlightBuiltins = 1
158
+let g:vimclojure#ParenRainbow = 1
159
+let g:virtualenv_directory = "$HOME/python_envs"
160
+let maplocalleader=','
161
+let $PAGER=''
162
+let python_highlight_all = 1
163
+let python_no_tab_space_error=1
164
+let python_space_errors=1
165
+let vimclojure#WantNailgun = 1
166
+
167
+
168
+" IMPORTANT: grep will sometimes skip displaying the file name if you
169
+" search in a singe file. This will confuse Latex-Suite. Set your grep
170
+" program to always generate a file-name.
171
+
172
+" OPTIONAL: This enables automatic indentation as you type.
173
+filetype indent on
174
+
175
+" OPTIONAL: Starting with Vim 7, the filetype of empty .tex files defaults to
176
+" 'plaintex' instead of 'tex', which results in vim-latex not being loaded.
177
+" The following changes the default filetype back to 'tex':
178
+let g:tex_flavor='latex'
179
+
180
+" Configuration file for vim
181
+
182
+" Normally we use vim-extensions. If you want true vi-compatibility
183
+" remove change the following statements
184
+
185
+" Don't write backup file if vim is being called by "crontab -e"
186
+au BufWrite /private/tmp/crontab.* set nowritebackup
187
+" Don't write backup file if vim is being called by "chpass"
188
+au BufWrite /private/etc/pw.* set nowritebackup
189
+
190
+"Enable support for Color xterm
191
+:if has("terminfo")
192
+:  set t_Co=8
193
+:  set t_Sf=[3%p1%dm
194
+:  set t_Sb=[4%p1%dm
195
+:else
196
+:  set  t_Co=8
197
+:  set t_Sf=[3%dm
198
+:  set t_Sb=[4%dm
199
+:endif
200
+
201
+set omnifunc=syntaxcomplete#Complete
202
+set ignorecase
203
+set smartcase
204
+set autoindent
205
+set nu
206
+set expandtab
207
+set tabstop=3 softtabstop=2
208
+set smarttab
209
+set shiftwidth=2
210
+set incsearch
211
+set scrolloff=4
212
+set wildmode=longest,list
213
+set autoread
214
+set background=dark
215
+set pastetoggle=<F12>
216
+set undodir=~/.vim/undodir
217
+set undofile
218
+set undolevels=10000
219
+set undoreload=100000
220
+set foldlevel=9
221
+set hidden
222
+set laststatus=2
223
+set splitbelow
224
+set splitright
225
+set grepprg=grep\ -nH\ $*
226
+set modelines=1      " CVE-2007-2438
227
+set backspace=2      " more powerful backspacing
228
+
229
+syntax enable
230
+colorscheme solarized
231
+
232
+if &term =~ "xterm\\|rxvt"
233
+  " use an orange cursor in insert mode
234
+  let &t_SI = "\<Esc>]12;blue\x7"
235
+  " use a red cursor otherwise
236
+  let &t_EI = "\<Esc>]12;yellow\x7"
237
+  silent !echo -ne "\033]12;yellow\007"
238
+  " reset cursor when vim exits
239
+  autocmd VimLeave * silent !echo -ne "\033]112\007"
240
+  " use \003]12;gray\007 for gnome-terminal
241
+endif
242
+
243
+"SmartIndent for Python
244
+autocmd BufEnter *.hs compiler ghc
245
+au FocusLost * :wa
246
+
247
+function Checkft()
248
+  if &filetype==""
249
+    filetype detect
250
+  endif
251
+endfunction
252
+
253
+
254
+" when we reload, tell vim to restore the cursor to the saved position
255
+"autocmd FileType python map K \pW
256
+autocmd! BufNewFile * silent! 0r ~/.vim/skel/tmpl.%:e
257
+autocmd BufRead,BufNewFile *.twig set filetype=htmljinja
258
+autocmd BufRead,BufNewFile *.mako set ft=mako
259
+autocmd BufRead,BufNewFile *.md set dictionary+=/usr/share/dict/words ft=markdown
260
+autocmd BufReadPost * if line("'\"") > 1 && line("'\"") <= line("$") | exe "normal! g`\"" | endif
261
+autocmd BufRead,BufNewFile *.py set smartindent cinwords=if,elif,else,for,while,try,except,finally,def,class
262
+autocmd BufRead,BufNewFile *.tac set ft=python
263
+autocmd bufwritepost * call Checkft()
264
+autocmd BufWritePre *.py normal m`:%s/\s\+$//e ``
265
+
266
+"autocmd FileType haskell set omnifunc=necoghc#omnifunc
267
+autocmd FileType lisp set omnifunc=SlimvOmniComplete
268
+autocmd FileType markdown set linebreak tw=110 noexpandtab nosmartindent autoindent spelllang=en spell
269
+"autocmd FileType pandoc set linebreak tw=110 noexpandtab nosmartindent autoindent
270
+"autocmd FileType pantondoc set linebreak tw=110 noexpandtab nosmartindent autoindent
271
+autocmd FileType python set complete+=k~/.vim/syntax/python.vim "isk+=.,(
272
+"Diable the anti-python smart indent of #
273
+inoremap  # X#
274
+
275
+"Turn Syntax Highlighting on by default, and assume the xterm background is black
276
+imap <C-g> :Unite outline -buffer-name=outline -start-insert<CR>
277
+imap <F7> :Unite outline -buffer-name=outline -start-insert<CR>
278
+imap <F8> o
:,!pbpaste
279
+imap <F9> o
:,!pbpaste
280
+inoremap <expr> <C-L> ListItem()
281
+inoremap <expr> <C-R> ListReset()
282
+inoremap <F2> :set nonumber! foldcolumn=0<CR>
283
+inoremap <F3> :!spot_control pr<CR>
284
+inoremap <F4> :!spot_control p<CR><CR>
285
+inoremap <F5> :!spot_control n<CR>
286
+inoremap <Return> <Return><C-g>u
287
+"inoremap <Space> <Space><C-g>u
288
+"inoremap <Tab> <Tab><C-g>u
289
+
290
+map <BS> dh
291
+map <C-g> :Unite outline -buffer-name=outline -start-insert<CR>
292
+map CS :sil! :%s/\s\+$//g<CR>``:%s/^\(\t\+\)\( \+\(\t*\)\)\+/\1\3/gc<CR>``
293
+map <F7> :Unite outline -buffer-name=files -start-insert<CR>
294
+map <F8> o
:,!pbpaste<CR>
295
+map <F9> o
:,!pbpaste<CR>
296
+map <leader>f :Unite file -buffer-name=files -start-insert<CR>
297
+map <leader>q :Unite buffer -buffer-name=buffers -start-insert<CR>
298
+map W wb"_dwP
299
+map ZX :wq<cr>
300
+map ZZ :w<CR>
301
+
302
+nmap <Leader>ci <Plug>VCSCommit
303
+nnoremap <C-H> <C-W><C-H>
304
+nnoremap <C-J> <C-W><C-J>
305
+nnoremap <C-K> <C-W><C-K>
306
+nnoremap <C-L> <C-W><C-L>
307
+nnoremap <F2> :set nonumber!<CR>:set foldcolumn=0<CR>
308
+
309
+python << EOF
310
+import os
311
+import sys
312
+import vim
313
+for p in sys.path:
314
+    if os.path.isdir(p):
315
+        vim.command(r"set path+=%s" % (p.replace(" ", r"\ ")))
316
+EOF
317
+
318
+
319
+func ListItem()
320
+ let g:counter += 1
321
+ return g:counter
322
+endfunc
323
+
324
+func ListReset()
325
+ let g:counter = 0
326
+ return ''
327
+endfunc
328
+
329
+set diffopt=vertical,filler,iwhite,foldcolumn:0
330
+
331
+highlight PmenuSel ctermfg=LightGray  ctermbg=DarkRed
332
+
333
+if filereadable(".vim.custom")
334
+    so .vim.custom
335
+endif
336
+
337
+let g:syntastic_javascript_checkers = ['jshint']
338
+call unite#custom#source('file,file/new,buffer,file_rec','matchers','matcher_fuzzy')
339
+
340
+autocmd FileType unite call s:unite_my_settings()
341
+function! s:unite_my_settings()
342
+  " Overwrite settings.
343
+  let b:SuperTabDisabled=1
344
+  imap <buffer><expr> <C-v>     unite#do_action('vsplit')
345
+  imap <buffer><expr> <C-s>     unite#do_action('split')
346
+  imap <buffer>  <Tab>     <Plug>(unite_complete)
347
+  imap <buffer> <C-j>   <Plug>(unite_select_next_line)
348
+  imap <buffer> <Down>   <Plug>(unite_select_next_line)
349
+  imap <buffer> <C-k>   <Plug>(unite_select_previous_line)
350
+  imap <buffer> <Up>   <Plug>(unite_select_previous_line)
351
+
352
+  " exit with esc
353
+  nmap <buffer> <ESC> <Plug>(unite_exit)
354
+
355
+  " exit with ctrl-c
356
+  imap <buffer> <c-c> <Plug>(unite_exit)
357
+  nmap <buffer> <c-c> <Plug>(unite_exit)
358
+endfunction
359
+
360
+if executable('ag')
361
+  let g:unite_source_file_async_command = 'ag --follow --nocolor --nogroup --hidden -g "" --ignore ''.sass-cache'''
362
+  "https://github.com/ggreer/the_silver_searcher
363
+  "Use ag in unite grep source.
364
+  let g:unite_source_rec_async_command = ['ag', '--follow', '--nocolor', '--nogroup', '--hidden', '-g', '', '--ignore', '.git', '--ignore', '.sass-cache']
365
+  let g:unite_source_rec_async_command = ['ag', '--follow', '--nocolor', '--nogroup', '--hidden', '-g', '', '--ignore', '.git', '--ignore', '.sass-cache']
366
+  let g:unite_source_grep_command = 'ag'
367
+  let g:unite_source_grep_default_opts =
368
+        \ '--line-numbers --nocolor --nogroup --hidden --ignore ' .
369
+        \ '''.hg'' --ignore ''.svn'' --ignore ''.git'' --ignore ''.bzr'' ' .
370
+        \ '--ignore ''**/*.pyc'''
371
+  let g:unite_source_grep_recursive_opt = ''
372
+elseif executable('ack-grep')
373
+  let g:unite_source_grep_command = 'ack-grep'
374
+  " Match whole word only. This might/might not be a good idea
375
+  let g:unite_source_grep_default_opts = '--no-heading --no-color -a -H'
376
+  "let g:unite_source_grep_default_opts = '--no-heading --no-color -a -w'
377
+  let g:unite_source_grep_default_opts = '--exclude ''\.(git|svn|hg|bzr)'''
378
+  let g:unite_source_grep_recursive_opt = ''
379
+elseif executable('ack')
380
+  let g:unite_source_grep_command = 'ack'
381
+  let g:unite_source_grep_default_opts = '--no-heading --no-color -a -w'
382
+  let g:unite_source_grep_default_opts = '--exclude ''\.(git|svn|hg|bzr)'''
383
+  let g:unite_source_grep_recursive_opt = ''
384
+endif
385
+
386
+nnoremap [unite] <Nop>
387
+nmap <space> [unite]
388
+nmap [unite]s :<C-u>Unite -auto-preview grep:.<C-m>
389
+nmap [unite]o :<C-u>Unite outline -start-insert<C-m>
390
+nmap  [unite]f  :<C-u>Unite file_rec/async -start-insert<C-m>
391
+nmap  [unite]F  :<C-u>Unite file -start-insert<C-m>
392
+nmap  [unite]g  :<C-u>Unite file_rec/git -start-insert<C-m>
393
+nmap [unite]j :<C-u>Unite buffer -start-insert<C-m>
394
+nmap [unite]k :<C-u>Unite tab:no-current<C-m>
395
+nmap [unite]t :NERDTreeToggle<CR>
396
+nmap [unite]u :GundoToggle<CR>
397
+nmap [unite]r :!vagrant rsync<CR>
398
+nmap [unite]h :set hlsearch!<CR>
399
+nmap [unite]l :set list!<CR>
400
+
401
+" Reload
402
+map <silent> tu :call GHC_BrowseAll()<CR>
403
+" Type Lookup
404
+map <silent> tw :call GHC_ShowType(1)<CR>
405
+autocmd BufRead,BufNewFile *.css,*.scss,*.less setlocal foldmethod=marker foldmarker={,}
406
+
407
+command -nargs=+ Gadd Git add <q-args>