Navigation
Other Sites
My Stuff:
Search
Twitterings
Friday
10Oct2008

Git: Rebase

Another quick Git video, this time talking about the rebase command and how you can use it to keep a branch current with changes in the parent branch.



By the way, I'm really liking Viddler for hosting these videos, although I need to be a bit more careful about the aspect ratios of the videos I upload to keep the quality up.

The diagrams are done using the presentation mode of OmniGraffle Pro.

[Update: Jacob Farkas pointed out in the comments something that I should have mentioned: rebasing branches that you have already shared with others is a Bad Idea. Don't do it.]

Reader Comments (3)

One thing to note is that the commit ids on the MyFeature branch will necessarily change when you rebase, which could cause problems if that branch was pushed to anyone else.
Rebasing is really only safe when it's done to local branches.

October 10, 2008 | Unregistered CommenterJacob Farkas

I'm finding these git explanation extremely helpful in getting my head around how it all fits together. Looking forwards to more of them!

(One small point; should the master branch not be pointing at the pink B as soon as that's committed?)

October 10, 2008 | Unregistered CommenterPeter

I agree, these short videos are a great help. Regarding Jacob's point, if rebasing is problematic for a published branch, what is the recommended way to update such a branch?

October 13, 2008 | Unregistered CommenterErik

PostPost a New Comment

Enter your information below to add a new comment.

My response is on my own website »
Author Email (optional):
Author URL (optional):
Post:
 
Some HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>