Loading tutorials
git rebase --onto command depends on a precise picture of what a branch is. This chapter builds that picture and shows how to inspect it in a real repository. Later chapters use it to explain which commits a rebase copies and where it puts them.7 min readgit log, and merge from the command line. You should also know that a branch is a movable pointer to a commit. You do not need to have used git rebase before. By the end you will know exactly which commits a plain git rebase copies and 7 min readgit log output. It also assumes you know a branch is a movable pointer to a commit. You don't need to have used git rebase --onto before. This chapter explains the argument that decides which commits get replayed.7 min readgit rebase --onto command and how to write one from a description of what you want. It assumes you can commit, branch, switch, and read git log output. It also assumes you know a branch is a movable pointer to a commit, and that you have seen a plain `git rebase 6 min readgit rebase --onto <newbase> <upstream> <branch> is read. The upstream argument bounds the range upstream..branch, and those commits are copied onto the new base. You also need git log, branch creation and a clean working tree. The chapter covers how to check w6 min readgit rebase --onto: you started a branch from another feature branch, and now you want it to depend on main instead. It assumes you can commit, branch, switch, and read git log. It also assumes you know a branch is a movable pointer to a commit6 min readgit rebase --onto <newbase> <upstream> <branch> command and know that the commits in upstream..branch are the ones replayed. It also assumes you can read a merge conflict marker. Here you will learn what Git does when a replayed commit does not 6 min readgit log, know that a branch is a pointer to a commit, and have read the earlier chapters on the upstream..branch range and the three-argument form git rebase --onto <newbase> <upstream> <branch>. Here you use that form to delete a run of commits from the middl6 min readgit log. It also assumes you have read the earlier chapters on the upstream..branch range and the three-argument git rebase --onto <newbase> <upstream> <branch> form. Here you apply that form to one frequent situation: a branch buil6 min readgit rebase --onto <newbase> <upstream> <branch> from the earlier chapters. A rebase rewrites history, so a wrong upstream or a bad conflict resolution is easy to make. Git keeps enough information to put the bran7 min readgit rebase --onto, read git log --graph, and use git push with a remote such as origin. It also assumes you know that a remote-tracking branch such as origin/topic is your local record of where the remote branch was at your last fetch or push. The earlier c7 min read--update-refs saves you from re-pointing each branch by hand after a rebase.6 min read