Tag: merge

Accidentally merged other branches when using `git pull` with no arguments

Not knowing any better, I’d always used blissfully git pull (without arguments) to get remote updates. Now that we’re using branches, this has come back to haunt me. After doing a git pull, I noticed that my local master had been merged with the other branches as well, whereas on the remote, the branches are […]

Merging another person's contributions with minor changes

What is a good way to take someone else’s contribution and merge it into another branch, but making some minor adjustments in the process? There are no merge difficulties (in fact, a fast-forward would work), but there are some spelling errors and style differences that I would like to adjust. Obviously, I could merge (fast-forward) […]

git revert merge – neither mainline looks correct

I am trying to revert a faulty merge, but the revert changes from both commands do not look right. This is how I made the merge commit: # merge master into branch: git checkout branch git merge master # resolve conflicts git commit git push Now I want to revert that merge with: git log […]

What is the git command to diff against a remote which has not been merged yet?

This question already has an answer here: Git: Compare All Local Commits to Remote Repo Version 6 answers

Word generating conflicts on GIT

I’m using dropbox to hold my git repo, and among other things, I have Word documents there. Strangely, when I try to push a Word document that no one else has pushed (and I know by a fact), it says it’s a non linear merge and requires me to pull and manually merge before I […]

Work with merge of multiple git branches

I have 2 branches, A and B, that don’t conflict with each other and have master as an ancestor. I’d like to work with the result of merging the two branches together into AB, for testing, but only make code changes to A or B. The problem is that every time I commit a change […]

GIT: merge branches twice

I have a problem during merging two branches. Consider the following git history structure: A—B—C feature /(1) /(2) D—E—F—G master And I need to merge ‘feature’ branch in point (1) and (2). (1) merged without any problems, but the second one shows warning: refname ‘feature’ is ambiguous Already up-to-date. Could you help me, please? Thanks. […]

git : how to create a merge with a known outcome

I’m creating a potted project history in git from a series of zip snapshots taken during the project’s early development. We know we (me & him) have some cases where we diverged from a base point A, then merged our two versions B & C, back into an agreed update of version D. Typically we […]

svn or git or something else?

Our team is developing a game. I’d like to try separate prototype which is based on our code but will slightly be different. We use svn for code repository. Now for my own prototype, how should I set up a repo so that I can keep updates from the svn but won’t let me commit […]

Git – Merging from a template project – no subdirectory

I’m wondering if this is going to work… Say i have a project template something like that: . + resources/ + images/ 1.png 2.png I want to use this project as a template for other projects, so they would be essentially “cloned” from the template but maintained as a separate repository. However, I would still […]

Git Baby is a git and github fan, let's start git clone.