Don't recurse into parents marked uninteresting.
[git/gitweb-caching.git] / Documentation / git-rebase.txt
blobf037d1280eb629339d82bb1eabf0ede7a1e25708
1 git-rebase(1)
2 =============
4 NAME
5 ----
6 git-rebase - Rebase local commits to new upstream head.
8 SYNOPSIS
9 --------
10 'git-rebase' [--onto <newbase>] <upstream> [<branch>]
12 DESCRIPTION
13 -----------
14 git-rebase applies to <upstream> (or optionally to <newbase>) commits
15 from <branch> that do not appear in <upstream>. When <branch> is not
16 specified it defaults to the current branch (HEAD).
18 When git-rebase is complete, <branch> will be updated to point to the
19 newly created line of commit objects, so the previous line will not be
20 accessible unless there are other references to it already.
22 Assume the following history exists and the current branch is "topic":
24           A---B---C topic
25          /
26     D---E---F---G master
28 From this point, the result of the following commands:
30     git-rebase master
31     git-rebase master topic
33 would be:
35                   A'--B'--C' topic
36                  /
37     D---E---F---G master
39 While, starting from the same point, the result of the following
40 commands:
42     git-rebase --onto master~1 master
43     git-rebase --onto master~1 master topic
45 would be:
47               A'--B'--C' topic
48              /
49     D---E---F---G master
51 OPTIONS
52 -------
53 <newbase>::
54         Starting point at which to create the new commits. If the
55         --onto option is not specified, the starting point is
56         <upstream>.
58 <upstream>::
59         Upstream branch to compare against.
61 <head>::
62         Working branch; defaults to HEAD.
64 Author
65 ------
66 Written by Junio C Hamano <junkio@cox.net>
68 Documentation
69 --------------
70 Documentation by Junio C Hamano and the git-list <git@vger.kernel.org>.
72 GIT
73 ---
74 Part of the gitlink:git[7] suite