Mac上使用 git commit ,编辑完提交说明后,会提示 vi 出错误。需要git config --global core.editor /usr/bin/vim 指定完整路径来解决这个问题。http://www.phpvim.net/