Tag: rebase

Recover commit list after undoing an interactive rebase in git?

My situation: There are two remotes, origin and fork (the latter is owned by me). I checked out origin/devel, changed some code and committed like 5x to my local branch test. I pushed my commits to fork/test. Then I started an interactive rebase, while on my local test branch: git rebase -i –onto origin/devel Git […]

Performing git rebase interactive from Java code

When using git rebase –interactive from command line you got the list of commits in the terminal window then you modify them and save, at this moment the rebase process start then you can use git commit –amend and git rebase –continue to rewrite the history I’m trying to automate rewriting the whole history from […]

Cleaning a Git repository with rebase remote branches

We are aworking on a project with GIT, but the guy who launch the project and create the git repository doesn’t explain to the team how to correctly and properly use GIT. I just arrived into the team last week and I have been charged to clean up the repositories which are all messy. First […]

How do I reverse the effects of a rebase on my git branch?

I have three branches, one main and two branches I’ve been working off, A and B. I’ve kept main up to date with the origin and had pushed out A. Before pushing B, though, I made a mistake and rebased both A and main onto it. This means that the PR for B includes A. […]

git rebase. Too many conflicts in areas I would rather have master

My branch(B) that inherits from Master(M). Since time has passed M and B have diverged, however B only modifies an exclusive folder (f) in the tree. The goal is to keep B in sync with M. I understand that it need to resolve conflicts in folder (f), however is there a way to simplify this […]

Does “git svn rebase” damage a non-“git svn” repository?

By mistake I did the command git svn rebase in a “normal” git repository, that is, one that was not created using git svn clone. Unsurprisingly, I got some errors in the output: > git svn rebase Migrating from a git-svn v1 layout… Data from a previous version of git-svn exists, but .git/svn (required for […]

Git: why necessary to update master first?

I forked an open source project (let’s call it project X). In my own fork, I created a new branch (let’s call it feature-branch-1) to work on a feature for the next version of X. The owners of X created a new branch for the next version (let’s call it X/nextgen). Once I was done […]

Sharing git file conflicts

I’ve gotten myself into a pickle here with our git project. We’ve been forced (by circumstance) to split the team into two fronts, one side working on a massive upgrade/overhaul task, the other working on features/bugfixes on top of our last release (which was where the branches split off) Trouble is, that was six months […]

git merge and rebase two repositories

I need to merge two git repositories by rebasing the root of the second repository onto the head of the first one. While doing so, it should keep: the commit history all author dates + names all tags unmerged (feature) branches merged branches the two repositories have common files (same file name) and the content […]

git rebase as close to HEAD as possible?

I’ve got a private branch in git that I’ve not touched in a while. I’d like to rebase it on top of master, so I: git checkout master git pull git checkout my-branch git rebase master First, rewinding head to replay your work on top of it… Applying: a bunch of stuff Applying: more stuff […]

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