Reputation: 53
The "Vim opens asking for commit message after implicit non-conflicting merge" seems to be a relatively common issue, with what seems to be a relatively simple answer: git config --global core.mergeoptions --no-edit
.
Unfortunately this doesn't seem to work for me or at least 8 of the other 15 people in my class, and our instructor is a bit baffled as well (though to be fair he hasn't had the time to look into it beyond a quick google search or two). It isn't that big of an issue, as you can escape out easily enough with :q
, but it is something we'd like to know the answer to, and my google searches return Stack Overflow questions with --no-edit
as the solution (either via core or every time a pull is done).
My .gitconfig (minus personal info):
[mergetool "kdiff3"]
path = "/c/Program Files/KDiff3/kdiff3.exe"
[merge]
tool = kdiff3
[core]
mergeoptions = --no-edit
[mergetool]
keepBackup = false
And yet:
.
Does anyone know why the fix isn't working (ie: "Ya dun goofed in spelling 'options'"), or if there is a better/more reliable way to fix this?
Upvotes: 5
Views: 7721
Reputation: 3297
You need to add add export GIT_MERGE_AUTOEDIT=no
in the .bash_profile
and open a new bash.
You can do that with the next bash command:
echo 'export GIT_MERGE_AUTOEDIT=no' >> $HOME/.bash_profile && . $HOME/.bash_profile
I hope that helps :D
Upvotes: 14
Reputation: 3411
Fix this by adding export GIT_MERGE_AUTOEDIT=no
to the .bash_profile
file.
Upvotes: 2