Tag: rebase

How can I rebase as one commit using Git

My history looks somewhat like this but times 10: i – j – e’- k – h’- l – m feature-branch / a – b – c – d – e – f – g – h master (the apostrophes meaning cherry picks) I want to rebase to this: i – j – k – […]

How to fix commit order in GitHub pull requests, broken by git rebase?

When I write code I break it into small logical changes that are easy and quick to review. To do so, I use git rebase -i (interactive) to squash, drop and change order of commits. I’ve noticed this sometimes leads to a different order of commits on a GitHub pull request (though the order is […]

git – squash before rebasing

I have two branches: master and test-branch (which is branched off of master). My work has looked something like the following: git checkout master git checkout -b test-branch make a bunch of changes and commit them make more changes and do another commit git checkout master git pull -> out other people have made changes […]

Git: How to fix commit during rebase

I came across the following problem: During git rebase one of automatically resolved commits has an error, i.e. as a result of automatic resolution, a function declaration was introduced for the second time in the header file and compilation fails. My question is: is it possible to go back to that automatically resolved commit, resolve […]

Git. Rebase local branch atop local master. How do I ignore a single files changes?

With Git I am on a branch. I am rebasing the branch atop master. There is a conflict that I want to resolve by ignoring the branches version and accepting master’s version. How do I indicate I want to use master’s version of the file during the rebase-ing. Thanks, Doug

What is the proper way to do “Checkout with Rebase” and then push the merged files in Intellij IDEA

In Git, I have two branches: master and myFeatureBranch (which I created via IDEA’s new branch while I was on master). In the time since I created myFeatureBranch, other team members have committed several changes to master. I would like to bring in those changes, and I am aware that I will have merge conflicts. […]

Git: rebasing a conflicted merge commit

After finishing working on a topic branch, I merged the topic branch into master like following: o—*—o—o topic / \ o—o—o—*—o—o—+ master The commits marked with ‘*’ modified the same code, hence merging lead to merge conflicts that were resolved in the merge commit (marked with ‘+’). While I merged and resolved the conflicts, my […]

Squash first N commits of git history / keep the rest as is

Consider the following problem: Private Project containing some credentials in the early stages We want to go open source We need to get rid of the credentials in the history credentials are not in single files but in code Complicated history with several merges, pull requests etc. What I want to do: Squash all commits […]

Git move single commit from feature_branch to master

What is the simplest way to achieve this? from: –A–B \ 1–2–3 to: –A–B–2 \ 1–3 I can’t figure any simple way to achieve this (less than like 5 steps).

Git pull with rebase causing excessive conflicts. How can I fix our workflow?

We have a base system that is customized for each client. The base lives in its own repository, and each client lives in its own repository (originally cloned from base). The goal is to have the ability to add bug fixes/features to base, which can be propagated to clients, on demand. So far the workflow […]

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