Skip to content

Commit ae98df5

Browse files
authored
Merge pull request git-tips#160 from lmarvaud/patch-1
Add change a branch base tips
2 parents f2e6ca6 + bc869e3 commit ae98df5

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,7 @@ P.S: All these commands are tested on `git version 2.7.4 (Apple Git-66)`.
166166
* [Show git status short](#show-git-status-short)
167167
* [Checkout a commit prior to a day ago](#checkout-a-commit-prior-to-a-day-ago)
168168
* [Push a new local branch to remote repository and track](#push-a-new-local-branch-to-remote-repository-and-track)
169+
* [Change a branch base](#change-a-branch-base)
169170

170171
<!-- Don’t remove or change the comment below – that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
171172
<!-- @doxie.inject end toc -->
@@ -1167,5 +1168,10 @@ git checkout master@{yesterday}
11671168
git push -u origin <branch_name>
11681169
```
11691170
1171+
## Change a branch base
1172+
```sh
1173+
git rebase --onto <new_base> <old_base>
1174+
```
1175+
11701176
<!-- Don’t remove or change the comment below – that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
11711177
<!-- @doxie.inject end -->

0 commit comments

Comments
 (0)