1

When I resolve a conflict, I have a merge commit in addition to the "real commit" I've made. It looks as following:

Merge branch 'master' of http://myDomain.com/git/SIMULATOR 

What is the best way to squash it into my "real commit", so that I have only one commit when pushing it to the server?

2 Answers 2

1
git fetch origin git rebase master origin/master git push origin master 

PS. Read man git-rebase

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

Comments

1

If have an existing merge commit, you can use git rebase, as answered by defuz—but then you will have to resolve the conflicts again.

Otherwise, use git merge --squash to squash changes introduced by the merge into a single commit. Resolve the conflicts if any, and run git commit.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.