LoginSignup
4
3

More than 5 years have passed since last update.

git commit時にhint: Waiting for your editor to close the file... mvim -f: mvim: command not found

Last updated at Posted at 2018-04-11

git commitを行った際に下記エラーが発生。

hint: Waiting for your editor to close the file... mvim -f: mvim: command not found
error: There was a problem with the editor 'mvim -f'.
Please supply the message using either -m or -F option.

Gitがエディターを使おうとしてmvimなんてコマンドないっすと言われている。

解決方法

.gitconfigの設定を修正することで解決。

手順

# .gitconfigの内容を確認
$ less ~/.gitconfig
[core]
    excludesfile = /hogehoge/.gitignore_global
    editor = mvim ←こんな設定があるはず
    autocrlf = input
〜以下略〜

# 設定変更
$ git config --global core.editor vi

# .gitconfigが変更されていることを確認
$ less ~/.gitconfig 
4
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
3