Zi 字媒體
2017-07-25T20:27:27+00:00
有時候單 commit 修改幅度不小,或是需要做長一點的說明時,直接在 command line 打會有點不舒服
個人會習慣叫出 editor 來編輯
git commit -e
1
git commit -e
今天在新環境時剛好需要用到 commit -e,指令下去之後噴了兩行 error
[Calos.Calos-PC] git commit -e
error: cannot run vi: No such file or directory
error: There was a problem with the editor 'vi'.
1
2
3
[Calos.Calos-PC] git commit -e
error: cannot run vi: No such file or directory
error: There was a problem with the editor 'vi'.
core.editor 沒設定,在使用到需要利用 editor 進行的指令時就會出現這種錯誤
把 core.editor 設為 vim
git config --global core.editor vim
1
git config --global core.editor vim
搞定
[Git] 設定editor was last modified: 2017-09-15 by Calos
寫了
5860316篇文章,獲得
23313次喜歡