Tag: git merge

Git branch unknown to local clone

I have a git repository with two branches. If I clone my repo I can only see the master branch. I have both branches up to date. The problem is I don’t fully understand merging and branching. Darn it! My example can be seen here: http://github.com/rimian/rimian/network Can anyone tell me how to get this back […]

Git merge: merge a file with a different file

I have 2 branches A and B In branch A I renamed Thing.java to ThingImpl.java, and rewrote Thing.java so that it’s now an interface. I also added quite a bit to ThingImpl.java. In branch B I edited the class in Thing.java Now I’m trying to merge my changes from branch A into branch B, and […]

aborting a git merge and going back to uncommitted work

this is my situation: i forgot to pull and I started working on my project. what I worked on this morning is totally different from my last commit on that repository. I’m doing a commit and I’m prompted to pull, this is when i realized i will have an avalanche of unresolvable conflicts. i pull […]

How to merge the branch with no changes into master branch in git?

Having a basic doubt in git branching and merge . Can a branch be merged without any changes into master . If so , What happens to the delta changes that exists between master and branch . Will that be overridden with master branch changes . Refer the below scenario : I have two branches […]

Why does merging these branches do nothing?

Short version: I have two branches with different contents. When I am in one branch and do a merge from the other, it says “Already up-to-date”. How is this even possible? I’m not even doing a pull at this point, just a merge from a local branch, to keep things simple. Possibly too much detail […]

Edit all conflicting files in a git merge/rebase (special character safe)

In the middle of a git rebase, I have a status such as: $ git status –short M lib/tmuxinator.rb UU lib/tmuxinator/cli.rb UU lib/tmuxinator/config.rb A spec/fixtures/TMUXINATOR_CONFIG/TMUXINATOR_CONFIG.yml M tmuxinator.gemspec How can I open the files with conflicts (denoted U above) in my text editor with a single command? The solution must work with \n and special characters […]

Git: How to checkout merge request locally, and create new local branch?

I have gitlab repository there I need to test every merge request locally, before merging to target branch. How can I pull/fetch merge request as a new branch?

Git: switch branches mid-merge

I just spent the last few hours resolving merge conflicts that resulted from merging big-feature-branch-B into big-feature-branch-A. I am finally finished and all my resolutions are staged and ready to be committed. However, the process where I work is to: Create a branch off of big-feature-branch-A (I’ll call this branch AB-merge-branch) Merge big-feature-branch-B into AB-merge-branch […]

Git reset –hard dont remove git merge errors

I treid to rebase my branch into another, but did something wrong which applied different patches to the same code, which resulted in alot of these: <<<<<<< HEAD <<<<<<< HEAD All over my project. Now when I try to undo all of these I did git reset –hard 44b76568 where 44b76568 is my latest commit […]

Why does git merge allow me to lose a line

We recently went through some merge issues with git, and while it probably did ‘The Right Thing'(TM) it wasn’t what I expected. I have reduced an issue to a small public github repository located at https://github.com/geretz/merge-quirk. quirk.c exists on master. merge-src and merge-dst are both branched from the same version on master, which is the […]

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