diff --git a/README.rst b/README.rst index 3812c78..411e565 100644 --- a/README.rst +++ b/README.rst @@ -3,7 +3,7 @@ Author: Chu-Siang Lai / chusiang (at) drx.tw Blog: http://note.drx.tw Filename: README.rst - Modified: 2018-03-19 01:28 + Modified: 2019-07-25 00:22 Reference: https://github.com/chusiang/vimrc/blob/master/README.rst ============================================================================= @@ -26,7 +26,7 @@ vimrc of chusiang :Requirements: Vim 7.4 or above. :Plugins Count: - 39 + 40 .. image:: https://lh6.googleusercontent.com/-jkam53cqxyk/Uo95ykP0eVI/AAAAAAAAWl4/ypRPFV90ul0/s800/2013-11-22-vim-chusiang.png :width: 720 px @@ -65,13 +65,6 @@ Linux & Mac OSX cd vimrc && make install -windows (No maintained) ------------------------ - -:: - - WindowsInstall.bat - 4. HowTo ======== @@ -323,7 +316,6 @@ Backup directory: `${HOME}/.vim_back-${data}` [#]_ ├── LICENSE ├── Makefile ├── README.rst - ├── WindowsInstall.bat ├── _gvimrc ├── _vim │   ├── 01.vimrc.vim @@ -344,12 +336,12 @@ Backup directory: `${HOME}/.vim_back-${data}` [#]_ │   ├── php-funclist.txt │   └── vimshrc ├── _vimrc - ├── _vimrc.win32 - ├── ctags.exe - └── doc - └── xterm-color-table.html + ├── dein_installer.sh + ├── doc + │   └── xterm-color-table.html + └── output.debian-9.log - 3 directories, 25 files + 3 directories, 24 files 7. Other vimrc list =================== diff --git a/WindowsInstall.bat b/WindowsInstall.bat deleted file mode 100644 index 5cd2c86..0000000 --- a/WindowsInstall.bat +++ /dev/null @@ -1,72 +0,0 @@ -::@echo off - -:: BatchGotAdmin -:------------------------------------- -REM --> Check for permissions ->nul 2>&1 "%SYSTEMROOT%\system32\cacls.exe" "%SYSTEMROOT%\system32\config\system" - -REM --> If error flag set, we do not have admin. -if '%errorlevel%' NEQ '0' ( - echo Requesting administrative privileges... - goto UACPrompt -) else ( - goto gotAdmin -) -:UACPrompt - echo Set UAC = CreateObject^("Shell.Application"^) > "%temp%\getadmin.vbs" - echo UAC.ShellExecute "%~s0", "", "", "runas", 1 >> "%temp%\getadmin.vbs" - "%temp%\getadmin.vbs" - exit /B - -:gotAdmin - if exist "%temp%\getadmin.vbs" ( del "%temp%\getadmin.vbs" ) - pushd "%CD%" - CD /D "%~dp0" -:-------------------------------------- - - -set HOME=%UserProfile% -set VIMFILES=%UserProfile%\vimfiles -set VIMRC=%UserProfile%\_vimrc - -echo Build VIM env directory... -mkdir "%VIMFILES%" - -echo Build Directory for autoload... -mkdir "%VIMFILES%\autoload" - -echo Copy base init file to %VIMFILES% -copy _vimrc.win32 "%VIMRC%" -copy ctags.exe C:\WINDOWS\system32\ -xcopy _vim\* "%VIMFILES%" /E /Y -copy _pentadactylrc "%HOME%" - -echo build vimrc shortcut... -::mklink "%VIMRC%" "%VIMFILES%"\_vimrc -copy _vimrc.win32 "%VIMRC%" - -echo Initial base plugin... -call :InstallCurl -git clone http://github.com/gmarik/vundle.git "%VIMFILES%/bundle/vundle" -::vim -c InitENV -echo -------Note------- -echo Must initial last env setting at vim :InitEnv -echo -------DONE------- -pause -goto exit - -:InstallCurl - @rem Do not use "echo off" to not affect any child calls. - @setlocal - - @rem Get the abolute path to the parent directory, which is assumed to be the - @rem Git installation root. - @for /F "delims=" %%I in ("%~dp0..") do @set git_install_root=%%~fI - @set PATH=%git_install_root%\bin;%git_install_root%\mingw\bin;%PATH% - - @if not exist "%HOME%" @set HOME=%HOMEDRIVE%%HOMEPATH% - @if not exist "%HOME%" @set HOME=%USERPROFILE% - - @curl.exe %* - -:exit diff --git a/_vimrc.win32 b/_vimrc.win32 deleted file mode 100644 index bfa5c68..0000000 --- a/_vimrc.win32 +++ /dev/null @@ -1,529 +0,0 @@ -" ============================================================ -" Author: chusiang / chusiang.lai (at) gmail.com -" Blog: http://note.drx.tw -" Filename: _vimrc.win32 -" Modified: 2014-12-30 17:07 -" Description: vimrc for win32. -" Reference: -" =========================================================== - -set nocompatible -source $VIMRUNTIME/vimrc_example.vim -source $VIMRUNTIME/mswin.vim -behave mswin - -set diffexpr=MyDiff() -function MyDiff() - let opt = '-a --binary ' - if &diffopt =~ 'icase' | let opt = opt . '-i ' | endif - if &diffopt =~ 'iwhite' | let opt = opt . '-b ' | endif - let arg1 = v:fname_in - if arg1 =~ ' ' | let arg1 = '"' . arg1 . '"' | endif - let arg2 = v:fname_new - if arg2 =~ ' ' | let arg2 = '"' . arg2 . '"' | endif - let arg3 = v:fname_out - if arg3 =~ ' ' | let arg3 = '"' . arg3 . '"' | endif - let eq = '' - if $VIMRUNTIME =~ ' ' - if &sh =~ '\ ' . arg3 . eq -endfunction - -" ---- Chu-siang Lai ---- -set ai -set guifont=Consolas:h11 " for Windows. -"set guifont=Monaco:h11 " for Linux. -set hls -set ic -set showmatch -set mouse=nv -set nobackup -set noswapfile -set nocompatible -"set number -set rnu -set tabstop=4 -set t_Co=256 " support 256 color. -set guioptions-=T "remove Toolbar. -set guioptions+=m " add Menu. -set guioptions-=e " Add tab page. -set guioptions-=b " remove Scroll (Below). -set guioptions-=l " remove Scroll (Left). -set guioptions-=L " remove Scroll (Left of Split window). -set guioptions-=r " remove Scroll (Right). -set guioptions-=R " remove Scroll (Right of Split window). -colorscheme fu " Favorites Color. - -"Put vim files in the temp directory instead of the current directory -set backupdir=C:\Windows\Temp - -" = keymap = -" quick quit vim. -nmap :x - -cmap WW :w -imap jj - -" disable event from mswin.vim -unmap -unmap - -" == Copy == -"vmap y -vmap "+y -"nmap "+gp - -" == Paste == -nmap v "+gp -nmap p :set paste -nmap np :set nopaste - -" == Hide Scroll of Split Windows mode == -nmap +b :set guioptions+=b -nmap +l :set guioptions+=L -nmap +r :set guioptions+=r -nmap -b :set guioptions-=b -nmap -l :set guioptions-=L -nmap -r :set guioptions-=r - -" == Font Size == -nmap f0 :set guifont=Monaco:h11 -nmap f1 :set guifont=Monaco:h9 -nmap f2 :set guifont=Monaco:h10 -nmap f3 :set guifont=Monaco:h11 -nmap f4 :set guifont=Monaco:h12 -nmap f5 :set guifont=Monaco:h14 - -" == Tabs == -nmap tt :tabnew -nmap td :tabclose -nmap tj :tabnext -nmap tn :tabnext -nmap tk :tabprev -nmap tp :tabprev -nmap te :Texplore - -" == Indent == -nmap v> - -" == $SHELL on Windows == -"set shell=C:\cygwin\bin\bash.exe -"set shellcmdflag='-c' -set shell=C:\cygwin\bin\bash.exe -set shellcmdflag=--login\ -c -set shellxquote=\" - -" = abbreviation = -" == insert mode == -iabbr addons Add-ons -iabbr apti aptitude -iabbr cubu Canonical -iabbr centos CentOS -iabbr chr Chrome -iabbr comm command -iabbr fir Firefox -iabbr gon Gnome -iabbr goo Google -iabbr lin Linux -iabbr Lin Linux -iabbr moz Mozilla -iabbr mic Microsoft -iabbr Mic Microsoft -iabbr ore O'reilly -iabbr nVi nVidia -iabbr tp ThinkPad -iabbr ubu Ubuntu -iabbr vbx Virtualbox -iabbr vl vim-like -iabbr Vimp Vimperator -iabbr pent Pentadactyl -iabbr scr scripts -iabbr w7 Windows7 -iabbr Win Windows -iabbr winxp WindowsXP - -" = encode = -" == utf-8 == -set encoding=utf-8 -"set termencoding=utf-8 -set fileencodings=ucs-bom,utf-8,chinese,latin-1 -if has("win32") - set fileencoding=chinese -else - set fileencoding=utf-8 -endif - -" == big5 == -set langmenu=zh_TW.utf-8 -source $VIMRUNTIME/delmenu.vim -source $VIMRUNTIME/menu.vim - -language messages zh_tw.utf-8 "console encode. - -" == Plugin with Vundle == - -set nocompatible " be iMproved, required -filetype off " required - -set rtp+=~/vimfiles/bundle/vundle/ -let path='~/vimfiles/bundle' -call vundle#rc(path) -"if has('win32') -" set runtimepath+=%UserProfile%\vimfiles/bundle/vundle.vim/ -" let path='~/vimfiles/bundle' -" call vundle#rc(path) -"else -" set runtimepath+=~/.vim/bundle/vundle.vim/ -" call vundle#rc() -"endif - -" let Vundle manage Vundle, required -Plugin 'gmarik/vundle' - -" ## snipMate (auto-complete) -Plugin 'MarcWeber/vim-addon-mw-utils' -Plugin 'tomtom/tlib_vim' -Plugin 'honza/vim-snippets' -Plugin 'garbas/vim-snipmate' - -" ## vim-airline -" replace 'vim-powerline'. -Plugin 'bling/vim-airline' -"let g:airline_powerline_fonts = 1 - -" ## Vim Auto Complete Popup (need L9) -Plugin 'othree/vim-autocomplpop' -Plugin 'L9' -" autocomplete with snippets. -let g:acp_behaviorSnipmateLength = 1 - -" ## c.vim -Plugin 'c.vim' - -" ## calendar.vim -"Plugin 'calendar.vim' -Plugin 'calendar.vim--Matsumoto' -nmap wc :Calendar - -" ## Colorscheme -"Plugin 'flazz/vim-colorschemes' -"Plugin 'mukiwu/vim-tomorrow-night' -Plugin 'chriskempson/vim-tomorrow-theme' - -" ## ctrlp.vim -Plugin 'kien/ctrlp.vim.git' -let g:ctrlp_map = '' -let g:ctrlp_cmd = 'CtrlP' -let g:ctrlp_working_path_mode = 'ra' - -set wildignore+=*/tmp/*,*.so,*.swp,*.zip " MacOSX/Linux -set wildignore+=*\\tmp\\*,*.swp,*.zip,*.exe " Windows - -"let g:ctrlp_custom_ignore = '\v[\/]\.(git|hg|svn)$' -let g:ctrlp_custom_ignore = { - \ 'dir': '\v[\/]\.(git|hg|svn)$', - \ 'file': '\v\.(exe|so|dll|cfg|desktop)$', - \ 'link': 'some_bad_symbolic_links', -\ } -let g:ctrlp_user_command = { - \ 'types': { - \ 1: ['.git', 'cd %s && git ls-files -c -o'], - \ 2: ['.hg', 'hg --cwd %s locate -I .'], - \ }, - \ 'fallback': 'find %s -type f' -\ } - -" ## easymotion -"Plugin 'Lokaltog/vim-easymotion' -""end easymotion - -" ## EditorConfig -"Plugin 'editorconfig/editorconfig-vim' - -" ## EnhCommentify.vim -Plugin 'EnhCommentify.vim' - -" ## Gitv (need the fugitive plugin) -"Plugin 'gitv' -"Plugin 'gregsexton/gitv' -Plugin 'tpope/vim-fugitive' -"nmap gv :Gitv --all -"nmap gV :Gitv! --all -"vmap gV :Gitv! --all - -" ## Global Session -"Plugin 'c9s/gsession.vim' -""Plugin 'gsession.vim' -"let g:session_dir = '$HOME/.vim/session' -""let g:local_session_filename = '.session.vim' -"let g:autoload_session = 0 -"let g:autosave_session = 0 -""let g:gsession_non_default_mapping = 1 - -" ## Vim Git Gutter -"Plugin 'airblade/vim-gitgutter' - -"You can explicitly turn vim-gitgutter off and on (defaults to on): -" -" turn off with :GitGutterDisable -" turn on with :GitGutterEnable -" toggle with :GitGutterToggle. -"nmap d :GitGutterToggle -" -"And you can turn line highlighting on and off (defaults to off): -" -" turn on with :GitGutterLineHighlightsEnable -" turn off with :GitGutterLineHighlightsDisable -" toggle with :GitGutterLineHighlightsToggle. -" -"Furthermore you can jump between hunks: -" -" jump to next hunk: ]h -" jump to previous hunk: [h. -" -"nmap gh GitGutterNextHunk -"nmap gH GitGutterPrevHunk - -" ## HTML5 omnicomplete and syntax -Plugin 'othree/html5.vim' - -" ## Matchit -Plugin 'matchit.zip' - -" ## mru.vim -Plugin 'mru.vim' - -" ## NERDTree -Plugin 'scrooloose/nerdtree' -nmap e :NERDTree -nmap :NERDTree - -" ## vim-notes -Plugin 'xolox/vim-notes.git' -Plugin 'xolox/vim-misc.git' -let g:notes_directories = ['~/Dropbox/notes'] -let g:notes_suffix = '.txt' - -" ## numbers.vim -"Plugin 'myusuf3/numbers.vim' -"nnoremap :NumbersToggle - -" ## Omni Complete -set ofu=syntaxcomplete#Complete -map :!ctags -R --c++-kinds=+p --fields=+iaS --extra=+q . - -" - Enable omni completion. -autocmd FileType css setlocal omnifunc=csscomplete#CompleteCSS -autocmd FileType html,markdown setlocal omnifunc=htmlcomplete#CompleteTags -autocmd FileType javascript setlocal omnifunc=javascriptcomplete#CompleteJS -autocmd FileType python setlocal omnifunc=pythoncomplete#Complete -autocmd FileType xml setlocal omnifunc=xmlcomplete#CompleteTags - -" - Enable heavy omni completion. -if !exists('g:neocomplcache_omni_patterns') - let g:neocomplcache_omni_patterns = {} -endif - -"let g:neocomplcache_omni_patterns.ruby = '[^. *\t]\.\w*\|\h\w*::' -"autocmd FileType ruby setlocal omnifunc=rubycomplete#Complete -let g:neocomplcache_omni_patterns.php = '[^. \t]->\h\w*\|\h\w*::' -"let g:neocomplcache_omni_patterns.c = '\%(\.\|->\)\h\w*' -"let g:neocomplcache_omni_patterns.cpp = '\h\w*\%(\.\|->\)\h\w*\|\h\w*::' - -" ## OmniCppComplete -"Plugin 'OmniCppComplete' -" -"set tags+=~/vimfiles/tags/tags -"set tags+=~/vimfiles/tags/c++.tags -"set tags+=~/vimfiles/tags/stl-3.3.tags -"autocmd CursorMovedI * if pumvisible() == 0|pclose|endif -"autocmd InsertLeave * if pumvisible() == 0|pclose|endif -"let OmniCpp_DefaultNamespaces = ["std", "_GLIBCXX_STD"] -"let OmniCpp_MayCompleteDot = 1 " autocomplete with . -"let OmniCpp_MayCompleteArrow = 1 " autocomplete with -> -"let OmniCpp_MayCompleteScope = 1 " autocomplete with :: -"let OmniCpp_SelectFirstItem = 2 " select first item (but don't insert) -"let OmniCpp_NamespaceSearch = 2 " search namespaces in this and included files - -" ## phpfolding.vim -"Plugin 'phpfolding.vim' -"autocmd FileType php noremap :!php -l % -"autocmd FileType php noremap :EnableFastPHPFolds -"autocmd FileType php noremap :EnablePHPFolds -"autocmd FileType php noremap :DisablePHPFolds - -" ## Powerline for Vim -"Plugin 'Lokaltog/vim-powerline' -"set laststatus=2 -"set fillchars+=stl:\ ,stlnc:\ -"let g:Powerline_symbols = 'fancy' -"set -g default-terminal 'screen-256color' - -" ## pythoncomplete -Plugin 'pythoncomplete' - -" ## Ragtag -Plugin 'tpope/vim-ragtag' - -" ## syntastic: Syntax checking hacks for vim. -Plugin 'scrooloose/syntastic.git' -"let g:syntastic_error_symbol='✗' -"let g:syntastic_warning_symbol='⚠' -let g:syntastic_enable_highlighting = 1 -let g:syntastic_stl_format = '[%E{Err: %fe #%e}%B{, }%W{Warn: %fw #%w}]' - -" ## SrcExpl -"Plugin 'wesleyche/SrcExpl' -"map s :SrcExplToggle -" -"" // The switch of the Source Explorer -"" nmap :SrcExplToggle -"" -"" " // Set the height of Source Explorer window -"" let g:SrcExpl_winHeight = 8 -"" -"" " // Set 100 ms for refreshing the Source Explorer -"" let g:SrcExpl_refreshTime = 100 -"" -"" // Set 'Enter' key to jump into the exact definition context -"" let g:SrcExpl_jumpKey = '' -"" -"" // Set 'Space' key for back from the definition context -"" let g:SrcExpl_gobackKey = '' -"" -"" " // In order to Avoid conflicts, the Source Explorer should know what plugins -"" " // are using buffers. And you need add their bufname into the list below -"" " // according to the command ':buffers!' -" let g:SrcExpl_pluginList = [ -" \ '__Tag_List__', -" \ '_NERD_tree_', -" \ 'Source_Explorer' -" \ ] -"" -"" // Enable/Disable the local definition "searching, and note that this is not -"" // guaranteed to work, the Source Explorer "doesn't check the syntax for now. -"" // It only searches for a match with the keyword according to command 'gd' -"let g:SrcExpl_searchLocalDef = 1 -" -"" // Do not let the Source Explorer update the "tags file when opening -"let g:SrcExpl_isUpdateTags = 0 -" -"" // Use 'Exuberant Ctags' with '--sort=foldcase "-R .' or '-L cscope.files' to -"" // create/update the tags file -"let g:SrcExpl_updateTagsCmd = 'ctags --sort=foldcase -R .' -" -"" // Set '' key for updating the tags file "artificially -""let g:SrcExpl_updateTagsKey = '' -" -"" // Set '' key for displaying the previous definition in the jump list -""let g:SrcExpl_prevDefKey = '' -" -"" // Set '' key for displaying the next "definition in the jump list -""let g:SrcExpl_nextDefKey = '' - -" ## Sublime Text like. -"Plugin 'terryma/vim-multiple-cursors' -"let g:multi_cursor_use_default_mapping=0 -"let g:multi_cursor_next_key='' -"let g:multi_cursor_prev_key='' -"let g:multi_cursor_skip_key='' -"let g:multi_cursor_quit_key='' - -" ## reStructuredText in Vim -Plugin 'Rykka/riv.vim' - -" ## surround -" ex. [chusiang] → 'chusiang', chusiangchusiang -Plugin 'tpope/vim-surround' -"Plugin 'surround' - -" ## sdcv -Plugin 'chusiang/vim-sdcv' -nmap w :call SearchWord() - -" ## Tagbar -Plugin 'majutsushi/tagbar' -let g:tagbar_autofocus = 1 -let g:tagbar_sort = 0 -nmap t :TagbarToggle -nnoremap :TagbarToggle - -if has('win32') - let g:tagbar_ctags_bin='C:\Windows\System32\ctags.exe' - let Tlist_Ctags_Cmd = 'C:\Windows\System32\ctags.exe' -endif - -" ## TagList -Plugin 'taglist.vim' -"nmap t :Tlist - -" ## Trinity (SrcExpl need) -Plugin 'wesleyche/Trinity' - -" ## vimcdoc-tw -Plugin 'chusiang/vimcdoc-tw' -"set helplang=tw - -" ## vim-indent-object -"Plugin 'michaeljsmith/vim-indent-object' - -" ## Vimwiki -Plugin 'vimwiki' - -" - g:vimwiki_list* *vimwiki-multiple-wikies*. -let wiki_1 = {} -let wiki_1.path = '~/vimwiki/' -let wiki_1.index = 'index' - -let g:vimwiki_list = [wiki_1] - -" - Header level color. -:hi VimwikiHeader1 guifg=#FF0000 " Red -:hi VimwikiHeader2 guifg=#FFDB00 " Yellow -:hi VimwikiHeader3 guifg=#9C9CE0 " Light Purple -:hi VimwikiHeader4 guifg=#91B9E0 " Light Blue -:hi VimwikiHeader5 guifg=#999999 " Light Grey -:hi VimwikiHeader6 guifg=#49D432 " Light Green - -" - Default Browser. -let g:vimwiki_browsers=['/usr/bin/firefox'] - -" - Keymap -autocmd BufRead,BufNewFile *.wiki noremap wtb :VimwikiTable -autocmd BufRead,BufNewFile *.wiki noremap wj :VimwikiDiaryNextDay -autocmd BufRead,BufNewFile *.wiki noremap wk :VimwikiDiaryPrevDay -autocmd BufRead,BufNewFile *.wiki noremap wo - -" ## VST (Vim reStructured Text) -Plugin 'VST' -let g:vst_write_export=1 " plugin of vst default export html. - -" ## Start Syntax -Plugin 'BBCode--Dahn' -Plugin 'othree/vim-javascript-syntax' -Plugin 'css3' -Plugin 'hail2u/vim-css3-syntax' -Plugin 'css_color.vim' -Plugin 'gorodinskiy/vim-coloresque' -Plugin 'jQuery' -Plugin 'php.vim' -"Plugin 'cpp.vim' -"Plugin 'django.vim' -Plugin 'jgb/django.vim' -Plugin 'Python-Syntax' -Plugin 'nginx.vim' -"Plugin 'rest.vim' -"set syntax=rest -Plugin 'plasticboy/vim-markdown' -Plugin 'guns/xterm-color-table.vim.git' - -filetype plugin indent on " required - diff --git a/ctags.exe b/ctags.exe deleted file mode 100644 index 8847dd7..0000000 Binary files a/ctags.exe and /dev/null differ