spf13 vim

spf13 vim

  • spf13 vim
  • Installation on linux
  • Requires Git 1.7+ and Vim 7.3+
  • curl https://j.mp/spf13-vim3 -L > spf13-vim.sh && sh spf13-vim.sh

install

[dennis@localhost ~]$ curl https://j.mp/spf13-vim3 -L > spf13-vim.sh 
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   142  100   142    0     0     79      0  0:00:01  0:00:01 --:--:--    79
  0     0    0     0    0     0      0      0 --:--:--  0:00:03 --:--:--     0
100  5214  100  5214    0     0   1036      0  0:00:05  0:00:05 --:--:--  6998
[dennis@localhost ~]$ sh spf13-vim.sh 
Attempting to back up your original vim configuration.
‘/home/dennis/.vim’ -> ‘/home/dennis/.vim.20151007_1444202174’
‘/home/dennis/.vimrc’ -> ‘/home/dennis/.vimrc.20151007_1444202174’
Trying to update spf13-vim
Cloning into '/home/dennis/.spf13-vim-3'...
remote: Counting objects: 3303, done.
remote: Total 3303 (delta 0), reused 0 (delta 0), pack-reused 3303
Receiving objects: 100% (3303/3303), 3.16 MiB | 16.00 KiB/s, done.
Resolving deltas: 100% (1485/1485), done.
Checking connectivity... done.
[✔] Successfully cloned spf13-vim.
[✔] Setting up vim symlinks.
Trying to update vundle
Cloning into '/home/dennis/.vim/bundle/vundle'...
remote: Counting objects: 2941, done.
remote: Total 2941 (delta 0), reused 0 (delta 0), pack-reused 2941
Receiving objects: 100% (2941/2941), 870.60 KiB | 19.00 KiB/s, done.
Resolving deltas: 100% (1012/1012), done.
Checking connectivity... done.
[✔] Successfully cloned vundle.
[✔] Now updating/installing plugins using Vundle

Thanks for installing spf13-vim.
© 2015 http://vim.spf13.com/

[dennis@localhost ~]$ ls .vim/bundle/
auto-pairs           tagbar                    vim-less
ctrlp-funky          tlib_vim                  vim-litecorrect
ctrlp.vim            undotree                  vim-markdown
fonts                vim-abolish               vim-multiple-cursors
gist-vim             vim-addon-mw-utils        vim-nerdtree-tabs
HTML-AutoCloseTag    vim-airline               vim-over
matchit.zip          vim-bufferline            vim-php-namespace
neocomplete.vim      vim-coffee-script         vim-preview
neosnippet           vim-coloresque            vim-rails
neosnippet-snippets  vim-colors                vim-repeat
nerdcommenter        vim-colorschemes          vim-signify
nerdtree             vim-colors-solarized      vim-snippets
PIV                  vim-commentary            vim-surround
pythoncomplete       vim-css3-syntax           vim-textobj-indent
python_match.vim     vim-cucumber              vim-textobj-quote
python-mode          vim-cucumber-align-pipes  vim-textobj-sentence
python.vim           vim-easymotion            vim-textobj-user
restore_view.vim     vim-fugitive              vim-toml
rust.vim             vim-haml                  vim-twig
salt-vim             vim-indent-guides         vim-wordy
sessionman.vim       vim-javascript            vundle
syntastic            vim-json                  webapi-vim
tabular              vim-jst                   wildfire.vim
[dennis@localhost ~]$ du .vim -sh
125M    .vim
[dennis@localhost ~]$ tar zcf tab.tar.gz .vim
[dennis@localhost ~]$ ls -lh tab.tar.gz 
-rw-rw-r--. 1 dennis dennis 67M Oct  7 17:07 tab.tar.gz

Plugin instroduce

  • Vundle The best plugin manager
  • NERDTree
    • quick start/close using ctrl+e
    • o open selected file
    • r refresh selected folder
    • C select root directory
    • m add/delete/move/copy
    • ctrl+h/l switch window to left or right
  • ctrlp
    • quick start/close with ctrl+p
  • Tagbar
    • quick start/close with <leader>tt
  • EasyMotion
    • ,,w move foreword
    • ,,b move backword
  • Surround managing all the ‘“[{}]”‘ etc, using :help surround for more
    • cs'" , change ' to "
    • ysiw" , add " around the word
    • ysiw[
    • ysiw<p>
    • ds' , delete ' around the word
  • neocwomplcache autocomplete++
  • Fugitive
    • <leader>gs :Gstatus
    • <leader>gd :Gdiff
    • <leader>gc :Gcommit
    • <leader>gb :Gblame
    • <leader>gl :Glog
    • <leader>gp :Git push
  • Tabularize align everything
    • <Leader>a= :Tabularize /=
    • <Leader>a: :Tabularize /:
    • <Leader>a:: :Tabularize /:\zs
    • <Leader>a, :Tabularize /,
    • <Leader>a<Bar> :Tabularize
  • NERDCommenter
    • allow you to wrangle your code comments.
    • <leader>c<space>
  • numbers.vim
    • better line numbers
  • Airline
    • provide a lightweight themable statusline with no external dependencies.
  • Syntastic integrated syntax checking

Weakness

  • More suitable for the front-end program (html and python)
  • Too many plugins, and too big (100+MB)
  • Ag better than Ack
  • Not include vimshell and vimproc

Advantage (just for me)

  • NERDTree
  • Tagbar
  • EasyMotion
  • Surround

More powerful plugin

YouCompleteMe install offline

Reference