Tag: git merge

How can I undo a git rebase that's already been pulled/merged?

I’m in an odd predicament – we had a developer perform a “git pull –rebase” across branches multiple times, and I’m trying to repair the damage. Our graph originally looked like this: [master] A–B (origin/master) ___\________________________ [branch] \ C–D–E (origin/branch) After the faulty merges, our graph now looks something like this: [master] A–B—————H–I (origin/master) \ […]

Git: Add merge rule to config for specific file

I am using git to track a large LaTeX document which I write using Kile on different machines. Kile writes to its .kilepr config file when closing Kile. The problem I often run into is that I commit before closing Kile. So I commit and push, work on the other machine, and when I come […]

Merge two identical git-svn branch HEADs without losing link with git-svn remote branch?

I’ve got a pair of git-svn branches which have been manually kept in sync by applying patches and what-not; git-merge has not been used. The branches are now in sync, which is to say that git diff A B has no output at all. [A] +—-+–+–+–+——–+—+——–+-+—+-> \ / X / / \ \ X / […]

what are “automerged” files in git, and how do you list them all?

I ran a git merge master –no-commit in a branch and the only output given was this: Auto-merging path/to/file Automatic Merge went well; stopped before committing as requested However, git diff HEAD –name-status shows that there are about 15 files that where modified (prefixed with ‘M’) and 3 files which were added (prefixed with ‘A’). […]

Git – Making Changes to Multiple Master Branches

My small group of developers creates and maintains interfaces to several different versions of our company’s core product. The different versions of our core product are mostly similar, but there are some differences which require us to keep our code in a separate branch for each version. Everything is in the same repository. We were […]

force git mergetool to amend a previously done merge

I use DiffMerge for 3-way merges in git. I just completed a mandatory merge job but realized I missed something out and would like to remerge and use the same 3-way GUI functionality. When I tried: git mergetool my/path/file.ext I got No files need merging How can I force mergetool to be able to do […]

How do I merge with –no-ff in SmartGit/hg?

If you want to keep track of the moment you started a new feature-branch you can use git merge –no-ff -m “merged feature-branch” some-feature-branch As described here. How can I achieve this using the SmartGit GUI?

Merge two similar Git repositories?

I have two repositories, one of which is a clone of the other. Essentially what happened was there was a first repo created (A) which then has had work and a bunch of history generated, and then a clone was taken by way of file copy but without creating a branch. The copied repo (B) […]

How to merge only once when master branch diverged?

let’s consider following scenario in local git repository that is synced with remote: ──(A)─┬─(B)── master │ └─(C)── branch after merge branch into master (locally, takes long time since (C)= many commits): ──(A)─┬─(B)─┬─(D)── master │ │ └─(C)─┘ branch During the merge this happened on the remote repository: ──(A)───(B)───(E)── master Now, I want to have this result: […]

git merge not creating merge commit, no MERGE_HEAD

Using Git on Linux, I have been working on two different branches based on master in parallel (call them A and B), and also created a third branch (call it M) which merges those two branches—so far with no non-merge commits of its own. After doing some work on one of the “primary” branches […]

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