Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Branch: master
Fetching contributors…

Cannot retrieve contributors at this time

245 lines (189 sloc) 6.798 kB
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
""" P L U G I N S O P T I O N S
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
"========== bufExplorer plugin ==========
let g:bufExplorerDefaultHelp=0
let g:bufExplorerShowRelativePath=1
map <leader>o :BufExplorer<cr>
"========== Minibuffer plugin ==========
let g:miniBufExplMapWindowNavVim = 1
let g:miniBufExplMapWindowNavArrows = 1
let g:miniBufExplMapCTabSwitchBufs = 1
let g:miniBufExplModSelTarget = 1
"let g:miniBufExplSplitBelow = 1
"let g:miniBufExplUseSingleClick = 1
"let g:miniBufExplVSplit = 25
"let g:miniBufExplorerMoreThanOne = 2
"let g:bufExplorerSortBy = "name"
autocmd BufRead,BufNew :call UMiniBufExplorer
map <leader>u :TMiniBufExplorer<cr>
"========== CloseTag ==========
" Only load CloseTag dealing with html/xml file.
autocmd FileType html,htmldjango,jinjahtml,eruby,mako let b:closetag_html_style=1
autocmd FileType html,xhtml,xml,htmldjango,jinjahtml,eruby,mako so ~/.vim/bundle/closetag.vim/plugin/closetag.vim
"========== Vim grep ==========
let Grep_Skip_Dirs = 'RCS CVS SCCS .svn generated'
set grepprg=/bin/grep\ -nH
"==========NERDTree ==========
function! ToggleNERDTree()
" Detect which plugins are open
if exists('t:NERDTreeBufName')
let nerdtree_open = bufwinnr(t:NERDTreeBufName) != -1
else
let nerdtree_open = 0
endif
" Perform the appropriate action
if nerdtree_open
NERDTreeClose
else
NERDTree
endif
endfunction
function! ToggleNERDTreeFind()
" Detect which plugins are open
if exists('t:NERDTreeBufName')
let nerdtree_open = bufwinnr(t:NERDTreeBufName) != -1
else
let nerdtree_open = 0
endif
" Perform the appropriate action
if nerdtree_open
NERDTreeClose
else
NERDTreeFind
endif
endfunction
let NERDTreeShowHidden = 1
" open NERDTree on CWD
" map <leader>f :NERDTreeToggle%:p:h<cr>
map <leader>f :call ToggleNERDTree()<cr>
map <leader>r :call ToggleNERDTreeFind()<cr>
"==========NERDCommenter ==========
let NERDSpaceDelims = 1
"==========Supertab ==========
" Let Supertab work with vim's builtin autocomplete
let g:SuperTabDefaultCompletionType = "context"
"==========Vim Session ==========
" don't restore help windows
set sessionoptions-=help
" Don't persist options and mappings because it can corrupt sessions.
set sessionoptions-=options
" Always persist Vim's window size.
set sessionoptions+=resize
" Also save tabs
set sessionoptions+=tabpages
" The session_directory
let g:session_directory = "~/.vim_session/"
let g:session_autoload = "no"
let g:session_autosave = "no"
" Restore the last used session
let g:session_default_to_last = 1
" vim ruby/rails/rspec/jquery api doc settings
let g:jquery_doc_command='open'
let g:ruby_doc_command='open'
"========== Ctrl-P ==========
" https://github.com/kien/ctrlp.vim
let g:ctrlp_map = '<c-p>'
" Set How Ctrl-P determines the working directory
" 0 - don’t manage working directory.
" 1 - the parent directory of the current file.
" 2 - the nearest ancestor that contains one of these directories or files: .git/ .hg/ .svn/ .bzr/ _darcs/
let g:ctrlp_working_path_mode = 2
" exclude files or directory from search
" with vim script regexp, needs to escape |, + as well
let g:ctrlp_custom_ignore = {
\ 'dir': '\.git$\|\.hg$\|\.svn$\|node_modules$\|vendor$\|.*cache$',
\ 'file': '\.exe$\|\.so$\|\.dll$',
\ 'link': 'some_bad_symbolic_links',
\ }
set wildignore+=*/tmp/*,*.so,*.swp,*.zip,.DS_Store " MacOSX/Linux
" use custom file listing command
" let g:ctrlp_user_command = 'find %s -type f'
"========== Zoomwin binding ==========
map <leader>zw :ZoomWin<cr>
"========== Powerline plugin ==========
set laststatus=2
let g:Powerline_colorscheme = 'default'
let g:Powerline_symbols = 'fancy'
"Shows a segment indicating that the current buffer has trailing white spaces.
call Pl#Theme#InsertSegment('ws_marker', 'after', 'lineinfo')
"========== Fugitive ==========
" auto delete the fugitive object buff
autocmd BufReadPost fugitive://* set bufhidden=delete
let g:fugitive_github_domains = ['http://git.zenhacks.org']
"========== Dash Interface ==========
nmap <silent> <leader>d <Plug>DashSearch
let g:dash_map = {
\ 'ruby' : 'ruby rails',
\ 'python' : 'python2',
\ 'javascript' : 'javascript jquery underscore'
\ }
"========== Use Greper with Ag ==========
nmap <silent> <leader>a <Plug>GreperWord
"========== Use Dbext Profile ==========
let g:dbext_default_profile_mysql = 'type=MYSQL:user=yangchenyun:passwd=3CTszAjyDMpBnFtYsf4tFq'
let g:dbext_default_profile = 'mysql'
let g:dbext_default_SQLITE_bin = 'sqlite3'
"========== TagBar ==========
nmap <F8> :TagbarToggle<cr>
if executable('coffeetags')
let g:tagbar_type_coffee = {
\ 'ctagsbin' : 'coffeetags',
\ 'ctagsargs' : '',
\ 'kinds' : [
\ 'f:functions',
\ 'o:object',
\ ],
\ 'sro' : ".",
\ 'kind2scope' : {
\ 'f' : 'object',
\ 'o' : 'object',
\ }
\ }
endif
let g:tagbar_type_markdown = {
\ 'ctagstype' : 'markdown',
\ 'kinds' : [
\ 'h:Heading_L1',
\ 'i:Heading_L2',
\ 'k:Heading_L3'
\ ]
\ }
"========== Vim Root ==========
let g:rooter_patterns = ['tags', 'Rakefile', 'MIT-LICENSE', '.git/', '.travis.yml', 'Gemfile', '*.gemspec']
let g:rooter_use_lcd = 1
"========== Syntastic ==========
let g:syntastic_ruby_mri_args="-w"
"========== Conque Shell ==========
let g:ConqueTerm_Color = 0
let g:ConqueTerm_FastMode = 1
function MyConqueStartup(term)
" set buffer syntax using the name of the program currently running
let syntax_associations = { 'ipython': 'python', 'irb': 'ruby', 'pry': 'ruby' }
if has_key(syntax_associations, a:term.program_name)
execute 'setlocal syntax=' . syntax_associations[a:term.program_name]
else
execute 'setlocal syntax=' . a:term.program_name
endif
" init fish instead for faster experience
if a:term.program_name == 'bash'
call a:term.writeln('fish')
endif
endfunction
call conque_term#register_function('after_startup', 'MyConqueStartup')
"========== Slimv Setup ==========
au BufNewFile,BufRead *.rkt setf scheme
let g:slimv_repl_split = 4 " Vertical right split buffer for output"
let g:slimv_leader = ",l"
let g:scheme_builtin_swank = 1
let g:lisp_rainbow=1
"========== CSupport ==========
let g:C_MapLeader = ','
let g:C_CCompiler = 'cc'
let g:C_ExeExtension = '.out'
"========== javaScript Lib ==========
let g:used_javascript_libs = 'jquery,angularjs,underscore,backbone'
"========== SQL ==========
let g:sql_type_default = 'pgsql'
"========== PIV ==========
let g:DisableAutoPHPFolding = 1
Jump to Line
Something went wrong with that request. Please try again.