0

I am simply trying to do a git pull which I have done hundreds of times. For some reason, this time it is showing me this in the console

# Please enter a commit message to explain why this merge is necessary,
# especially if it merges an updated upstream into a topic branch.
#
# Lines starting with '#' will be ignored, and an empty message aborts
# the commit.

however, nothing opens for me to enter this commit message. I believe something like Vim or whatever should open (which I have never used) but I am at a stalemate trying to pull code.

I see this in my git config

core.editor=vi

What can I do? Can I enter said commit message some other way? I am using Mac OSX Lion.

3
  • Are you trying to pull onto a branch on which you have made commits? Do you really want to do that? It looks in your question like vi did start. Commented Mar 16, 2013 at 0:34
  • If you don't understand vi, set your editor to BBEdit or freeware TextWrangler. Works very well with git. Commented Mar 16, 2013 at 0:35
  • I have no idea how to use vi. I do have TextWrangler. If TextWrangler exists in my Applications folder on Mac OSX, how do I set it as my editor? Commented Mar 16, 2013 at 0:45

2 Answers 2

2

If you have your git editor set to vi and you see that message at all it means you are in vi. If you know how to use vi, type your message. Otherwise, change the editor to an editor you're familiar with instead.

Sign up to request clarification or add additional context in comments.

1 Comment

I never realized that on the terminal title bar, 'bash' stealthily changes to 'vim'. And here I was waiting for a new window to open somewhere. Thanks!
1

To change the editor, do:

git config --global core.editor TextWrangler

(replace TextWrangler with the exact command to call your editor, preferably with the full path).

This changes the configuration for your account (all git repositories you use), with --local you change only the configuration for the current repository.

Also check for environment variables called GIT_<something>.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.