Today I found XVim which is a plugin for XCode, it offers a flood of funcitons of VIM for Xcode. Actrually, I only wnat the navigation functions. h,j,k,l,w,e,b are engough for me. When coding in XCode, I am comfortable with Apple’s touchboard. In Insert mode, I also prefer to use Emacs-like navigations, ctrl + n, p, e, a, d. So I made some modification in the rc file of XVim, a .xvimrc file in my home directory:

1
2
3
4
inoremap <C-e> <C-o>$
inoremap <C-n> <Down>
inoremap <C-p> <Up>
inoremap jk <Esc>

That’s it, enjoy!