Updated git_doc to git 1.8
[TortoiseGit.git] / doc / source / en / TortoiseGit / git_doc / git-cherry.xml
blob83af0ba1c849331dcf7c256e956b02c64fb56c3e
1 <?xml version="1.0" encoding="UTF-8"?>\r
2 <!DOCTYPE sect2 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">\r
3 \r
4 <sect2 lang="en" id="git-cherry(1)">\r
5     <title>git-cherry(1)</title>\r
6 <indexterm>\r
7 <primary>git-cherry(1)</primary>\r
8 </indexterm>\r
9 <simplesect id="git-cherry(1)__name">\r
10 <title>NAME</title>\r
11 <simpara>git-cherry - Find commits not merged upstream</simpara>\r
12 </simplesect>\r
13 <simplesect id="git-cherry(1)__synopsis">\r
14 <title>SYNOPSIS</title>\r
15 <blockquote>\r
16 <literallayout><emphasis>git cherry</emphasis> [-v] [&lt;upstream&gt; [&lt;head&gt; [&lt;limit&gt;]]]</literallayout>\r
17 </blockquote>\r
18 </simplesect>\r
19 <simplesect id="git-cherry(1)__description">\r
20 <title>DESCRIPTION</title>\r
21 <simpara>The changeset (or "diff") of each commit between the fork-point and &lt;head&gt;\r
22 is compared against each commit between the fork-point and &lt;upstream&gt;.\r
23 The commits are compared with their <emphasis>patch id</emphasis>, obtained from\r
24 the <emphasis>git patch-id</emphasis> program.</simpara>\r
25 <simpara>Every commit that doesn't exist in the &lt;upstream&gt; branch\r
26 has its id (sha1) reported, prefixed by a symbol.  The ones that have\r
27 equivalent change already\r
28 in the &lt;upstream&gt; branch are prefixed with a minus (-) sign, and those\r
29 that only exist in the &lt;head&gt; branch are prefixed with a plus (+) symbol:</simpara>\r
30 <literallayout class="monospaced">           __*__*__*__*__&gt; &lt;upstream&gt;\r
31           /\r
32 fork-point\r
33           \__+__+__-__+__+__-__+__&gt; &lt;head&gt;</literallayout>\r
34 <simpara>If a &lt;limit&gt; has been given then the commits along the &lt;head&gt; branch up\r
35 to and including &lt;limit&gt; are not reported:</simpara>\r
36 <literallayout class="monospaced">           __*__*__*__*__&gt; &lt;upstream&gt;\r
37           /\r
38 fork-point\r
39           \__*__*__&lt;limit&gt;__-__+__&gt; &lt;head&gt;</literallayout>\r
40 <simpara>Because <emphasis>git cherry</emphasis> compares the changeset rather than the commit id\r
41 (sha1), you can use <emphasis>git cherry</emphasis> to find out if a commit you made locally\r
42 has been applied &lt;upstream&gt; under a different commit id.  For example,\r
43 this will happen if you're feeding patches &lt;upstream&gt; via email rather\r
44 than pushing or pulling commits directly.</simpara>\r
45 </simplesect>\r
46 <simplesect id="git-cherry(1)__options">\r
47 <title>OPTIONS</title>\r
48 <variablelist>\r
49 <varlistentry>\r
50 <term>\r
51 -v\r
52 </term>\r
53 <listitem>\r
54 <simpara>\r
55         Verbose.\r
56 </simpara>\r
57 </listitem>\r
58 </varlistentry>\r
59 <varlistentry>\r
60 <term>\r
61 &lt;upstream&gt;\r
62 </term>\r
63 <listitem>\r
64 <simpara>\r
65         Upstream branch to compare against.\r
66         Defaults to the first tracked remote branch, if available.\r
67 </simpara>\r
68 </listitem>\r
69 </varlistentry>\r
70 <varlistentry>\r
71 <term>\r
72 &lt;head&gt;\r
73 </term>\r
74 <listitem>\r
75 <simpara>\r
76         Working branch; defaults to HEAD.\r
77 </simpara>\r
78 </listitem>\r
79 </varlistentry>\r
80 <varlistentry>\r
81 <term>\r
82 &lt;limit&gt;\r
83 </term>\r
84 <listitem>\r
85 <simpara>\r
86         Do not report commits up to (and including) limit.\r
87 </simpara>\r
88 </listitem>\r
89 </varlistentry>\r
90 </variablelist>\r
91 </simplesect>\r
92 <simplesect id="git-cherry(1)__see_also">\r
93 <title>SEE ALSO</title>\r
94 <simpara><xref linkend="git-patch-id(1)" /></simpara>\r
95 </simplesect>\r
96 <simplesect id="git-cherry(1)__git">\r
97 <title>GIT</title>\r
98 <simpara>Part of the <xref linkend="git(1)" /> suite</simpara>\r
99 </simplesect>\r
100 </sect2>\r