1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-03-13 02:05:40 +08:00

Split done

This commit is contained in:
wsdjeg 2017-01-14 20:14:14 +08:00
parent 4b9e71b5a5
commit 0a043c9b43
4 changed files with 45 additions and 74 deletions

View File

@ -3,6 +3,12 @@ function! SpaceVim#layers#edit#plugins() abort
\ ['tpope/vim-surround'],
\ ['terryma/vim-multiple-cursors'],
\ ['scrooloose/nerdcommenter'],
\ ['mattn/emmet-vim', { 'on_cmd' : 'EmmetInstall'}],
\ ['gcmt/wildfire.vim',{'on_map' : '<Plug>(wildfire-'}],
\ ['easymotion/vim-easymotion',{'on_map' : '<Plug>(easymotion-prefix)'}],
\ ['editorconfig/editorconfig-vim', { 'on_cmd' : 'EditorConfigReload'}],
\ ['floobits/floobits-neovim', { 'on_cmd' : ['FlooJoinWorkspace','FlooShareDirPublic','FlooShareDirPrivate']}],
\ ['lilydjwg/fcitx.vim', { 'on_i' : 1}],
\ ]
endfunction
@ -11,4 +17,16 @@ function! SpaceVim#layers#edit#config() abort
let g:multi_cursor_prev_key='<C-k>'
let g:multi_cursor_skip_key='<C-x>'
let g:multi_cursor_quit_key='<Esc>'
let g:user_emmet_install_global = 0
let g:user_emmet_leader_key='<C-e>'
let g:user_emmet_mode='a'
let g:user_emmet_settings = {
\ 'jsp' : {
\ 'extends' : 'html',
\ },
\}
noremap <SPACE> <Plug>(wildfire-fuel)
vnoremap <C-SPACE> <Plug>(wildfire-water)
let g:wildfire_objects = ["i'", 'i"', 'i)', 'i]', 'i}', 'ip', 'it']
map <Leader><Leader> <Plug>(easymotion-prefix)
endfunction

View File

@ -23,6 +23,13 @@ function! SpaceVim#layers#tools#plugins() abort
\ ['itchyny/calendar.vim', { 'on_cmd' : 'Calendar'}],
\ ['wsdjeg/Mysql.vim', { 'on_cmd' : 'SQLGetConnection'}],
\ ['wsdjeg/job.vim', { 'merged' : 0}],
\ ['junegunn/fzf', { 'on_cmd' : 'FZF'}],
\ ['ianva/vim-youdao-translater', { 'on_cmd' : ['Ydv','Ydc','Yde']}],
\ ['TaskList.vim', { 'on_cmd' : 'TaskList'}],
\ ['MarcWeber/vim-addon-mw-utils'],
\ ['taglist.vim',{'on_cmd' : 'TlistToggle', 'loadconf' : 1}],
\ ['scrooloose/nerdtree',{'on_cmd' : 'NERDTreeToggle', 'loadconf' : 1}],
\ ['Xuyuanp/nerdtree-git-plugin'],
\ ]
endfunction
@ -36,4 +43,21 @@ function! SpaceVim#layers#tools#config() abort
let g:rainbow#pairs = [['(', ')'], ['[', ']'],['{','}']]
" List of colors that you do not want. ANSI code or #RRGGBB
let g:rainbow#blacklist = [233, 234]
nnoremap <Leader>fz :FZF<CR>
vnoremap <silent> <C-l> <Esc>:Ydv<CR>
nnoremap <silent> <C-l> <Esc>:Ydc<CR>
map <unique> <Leader>td <Plug>TaskList
noremap <silent> <F8> :TlistToggle<CR>
function! OpenOrCloseNERDTree() abort
exec 'normal! A'
endfunction
noremap <silent> <F9> :NERDTreeToggle<CR>
let g:NERDTreeWinPos='right'
let g:NERDTreeWinSize=31
let g:NERDTreeChDirMode=1
autocmd bufenter * if (winnr('$') == 1 && exists('b:NERDTree') && b:NERDTree.isTabTree()) | q | endif
augroup nerdtree_zvim
autocmd!
autocmd FileType nerdtree nnoremap <silent><buffer><Space> :call OpenOrCloseNERDTree()<cr>
augroup END
endfunction

View File

@ -4,6 +4,9 @@ function! SpaceVim#layers#ui#plugins() abort
\ ['Yggdroot/indentLine'],
\ ['mhinz/vim-signify'],
\ ['majutsushi/tagbar', {'loadconf' : 1}],
\ ['vim-airline/vim-airline', { 'merged' : 0, 'loadconf' : 1}],
\ ['vim-airline/vim-airline-themes', { 'merged' : 0}],
\ ['mhinz/vim-startify', {'loadconf' : 1}],
\ ]
endfunction

View File

@ -4,81 +4,7 @@ function! SpaceVim#plugins#load() abort
call zvim#plug#begin(g:spacevim_plugin_bundle_dir)
call zvim#plug#fetch()
call s:load_plugins()
"web plugins
call zvim#plug#add('vim-airline/vim-airline', { 'merged' : 0})
call zvim#plug#add('vim-airline/vim-airline-themes', { 'merged' : 0})
if zvim#plug#tap('vim-airline')
call zvim#plug#defind_hooks('vim-airline')
endif
call zvim#plug#add('mattn/emmet-vim', { 'on_cmd' : 'EmmetInstall'})
let g:user_emmet_install_global = 0
let g:user_emmet_leader_key='<C-e>'
let g:user_emmet_mode='a'
let g:user_emmet_settings = {
\ 'jsp' : {
\ 'extends' : 'html',
\ },
\}
" use this two command to find how long the plugin take!
"profile start vim-javacomplete2.log
"profile! file */vim-javacomplete2/*
call zvim#plug#add('gcmt/wildfire.vim',{'on_map' : '<Plug>(wildfire-'})
noremap <SPACE> <Plug>(wildfire-fuel)
vnoremap <C-SPACE> <Plug>(wildfire-water)
let g:wildfire_objects = ["i'", 'i"', 'i)', 'i]', 'i}', 'ip', 'it']
call zvim#plug#add('easymotion/vim-easymotion',{'on_map' : '<Plug>(easymotion-prefix)'})
if zvim#plug#tap('vim-easymotion')
map <Leader><Leader> <Plug>(easymotion-prefix)
endif
call zvim#plug#add('MarcWeber/vim-addon-mw-utils')
call zvim#plug#add('mhinz/vim-startify')
if zvim#plug#tap('vim-startify')
call zvim#plug#defind_hooks('vim-startify')
endif
call zvim#plug#add('lilydjwg/fcitx.vim', { 'on_i' : 1})
"vim Wimdows config
call zvim#plug#add('scrooloose/nerdtree',{'on_cmd':'NERDTreeToggle'})
if zvim#plug#tap('nerdtree')
call zvim#plug#defind_hooks('nerdtree')
function! OpenOrCloseNERDTree() abort
exec 'normal! A'
endfunction
noremap <silent> <F9> :NERDTreeToggle<CR>
let g:NERDTreeWinPos='right'
let g:NERDTreeWinSize=31
let g:NERDTreeChDirMode=1
autocmd bufenter * if (winnr('$') == 1 && exists('b:NERDTree') && b:NERDTree.isTabTree()) | q | endif
augroup nerdtree_zvim
autocmd!
autocmd FileType nerdtree nnoremap <silent><buffer><Space> :call OpenOrCloseNERDTree()<cr>
augroup END
endif
call zvim#plug#add('Xuyuanp/nerdtree-git-plugin')
call zvim#plug#add('taglist.vim',{'on_cmd' : 'TlistToggle'})
if zvim#plug#tap('taglist.vim')
call zvim#plug#defind_hooks('taglist.vim')
noremap <silent> <F8> :TlistToggle<CR>
endif
"}}}
call zvim#plug#add('floobits/floobits-neovim', { 'on_cmd' : ['FlooJoinWorkspace','FlooShareDirPublic','FlooShareDirPrivate']})
call zvim#plug#add('TaskList.vim', { 'on_cmd' : 'TaskList'})
map <unique> <Leader>td <Plug>TaskList
call zvim#plug#add('ianva/vim-youdao-translater', { 'on_cmd' : ['Ydv','Ydc','Yde']})
vnoremap <silent> <C-l> <Esc>:Ydv<CR>
nnoremap <silent> <C-l> <Esc>:Ydc<CR>
call zvim#plug#add('editorconfig/editorconfig-vim', { 'on_cmd' : 'EditorConfigReload'})
call zvim#plug#add('junegunn/fzf', { 'on_cmd' : 'FZF'})
nnoremap <Leader>fz :FZF<CR>
call s:disable_plugins(g:spacevim_disabled_plugins)
call zvim#plug#end()
endif