I’m trying to use oh-my-zsh, tmux and spf13-vim. Actually most of my configurations come from OS X 11.11 El Capitanでターミナル環境を整える (Homebrew+zsh+tmux+vim). Yes, it’s written in Japenese and I have to use translator.

I just write down some accelerator key to help me remember it.

oh-my-zsh

I don’t change anything except I change ZSH_THEME to be robbyrussell.

tmux

This is not the default configuration, want to find the default configuration? use man tmux

key(Prefix C-z)  
defualt: C-b  
s show all sessions
v copy mode
r reload conf
| split-window -v
- split-window -v
h select-pane -L
j select-pane -D
k select-pane -U
l select-pane -R
C-h select-window -t :-
C-l select-window -t :+
Space select-window -t :+

PS: tmuxinator is your friend.

spf13-vim

I have learn a lot of plugins to finish this. You can use :help to learn basic vi. Just visiting spf13-vim will be fine. Default <Leader> key is \, but spf13-vim change it to be ,.

  • NERDTree file navigation

    1. <Leader>e to launch
    2. <C-E to toggle NERDTree
    3. <leader>e or <leader>nt to load NERDTreeFind which opens NERDTree where the current file is located.
  • ctrlp file finder

    1. <c-p> to launch
  • Surround managing all the ‘”[{}]”’ etc

    Old text Command New text ~
    “Hello *world!” ds” Hello world!
    [123+4*56]/2 cs]) (123+456)/2
    “Look ma, I’m *HTML!” cs” Look ma, I’m HTML!
    if *x>3 { ysW( if ( x>3 ) {
    my $str = *whee!; vllllS’ my $str = ‘whee!’;
  • NERDCommenter

    1. <Leader>c<space> to toggle comments
  • Syntastic integrated syntax checking

  • neocomplcache

    if you want to use it, you should install it with brew install vim --with-lua --override-system-vi

  • Fugitive

    1. <leader>gs :Gstatus
    2. <leader>gd :Gdiff
    3. <leader>gc :Gcommit
    4. <leader>gb :Gblame
    5. <leader>gl :Glog
    6. <leader>gp :Git push
  • Tabularize

    1. <Leader>a= :Tabularize /=
    2. <Leader>a: :Tabularize /:
    3. <Leader>a:: :Tabularize /:\zs
    4. <Leader>a, :Tabularize /,
    5. <Leader>a<Bar> :Tabularize /
  • Tagbar

    1. CTRL-] to jump to function definition
    2. <Leader>tt to toggle tagbar panel
    3. Ctrl-T to jump back up one level
  • EasyMotion

    1. <leader><leader> to trigger EasyMotion
  • :noautocmd vimgrep /{pattern}/ **/*

    1. :cprev previous file
    2. :cnext next file
    3. :cfirst first file
    4. :clast last file
  • buffers and tabs

    1. :buf num switch to num buffer
    2. :bn switch to next buffer
    3. :bp switch to previous buffer
    4. :bd delete buffer
  • add tabs to align code

    1. start visual mode ana use > or < to tab selected code
  • Use u to undo, and <C-R> to redo (reverse an undo).

These are the local plugins to use: