Error executing git commit

I am trying to do a git commit. I run the command git commitand vim opens. I enter my commit message, and when I execute the command :wq, I get the following error:

Error: There was a problem with the vi editor. Please put a message using the -m or -F option.

Any idea how I can understand what the problem is?

+4
source share
2 answers

To fix this problem, change the git editor path

git config --global core.editor /usr/bin/vim 

SOURCE

+5
source

If you want to restore the commit message, you can take a look .git/COMMIT_EDITMSG.

. git commit - , , (, ) , git commit.

0

All Articles