'\" t
.\" Title: git-cherry
.\" Author: [see the "Author" section]
.\" Generator: DocBook XSL Stylesheets v1.75.2
.\" Date: 08/16/2017
.\" Manual: Git Manual
.\" Source: Git 1.7.1
.\" Language: English
.\"
.TH "GIT\-CHERRY" "1" "08/16/2017" "Git 1\&.7\&.1" "Git Manual"
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.\" -----------------------------------------------------------------
.\" * MAIN CONTENT STARTS HERE *
.\" -----------------------------------------------------------------
.SH "NAME"
git-cherry \- Find commits not merged upstream
.SH "SYNOPSIS"
.sp
\fIgit cherry\fR [\-v] [ [ []]]
.SH "DESCRIPTION"
.sp
The changeset (or "diff") of each commit between the fork\-point and is compared against each commit between the fork\-point and \&. The commits are compared with their \fIpatch id\fR, obtained from the \fIgit patch\-id\fR program\&.
.sp
Every commit that doesn\(cqt exist in the branch has its id (sha1) reported, prefixed by a symbol\&. The ones that have equivalent change already in the branch are prefixed with a minus (\-) sign, and those that only exist in the branch are prefixed with a plus (+) symbol:
.sp
.if n \{\
.RS 4
.\}
.nf
__*__*__*__*__>
/
fork\-point
\e__+__+__\-__+__+__\-__+__>
.fi
.if n \{\
.RE
.\}
.sp
If a has been given then the commits along the branch up to and including are not reported:
.sp
.if n \{\
.RS 4
.\}
.nf
__*__*__*__*__>
/
fork\-point
\e__*__*____\-__+__>
.fi
.if n \{\
.RE
.\}
.sp
Because \fIgit cherry\fR compares the changeset rather than the commit id (sha1), you can use \fIgit cherry\fR to find out if a commit you made locally has been applied under a different commit id\&. For example, this will happen if you\(cqre feeding patches via email rather than pushing or pulling commits directly\&.
.SH "OPTIONS"
.PP
\-v
.RS 4
Verbose\&.
.RE
.PP
.RS 4
Upstream branch to compare against\&. Defaults to the first tracked remote branch, if available\&.
.RE
.PP
.RS 4
Working branch; defaults to HEAD\&.
.RE
.PP
.RS 4
Do not report commits up to (and including) limit\&.
.RE
.SH "SEE ALSO"
.sp
\fBgit-patch-id\fR(1)
.SH "AUTHOR"
.sp
Written by Junio C Hamano <\m[blue]\fBgitster@pobox\&.com\fR\m[]\&\s-2\u[1]\d\s+2>
.SH "DOCUMENTATION"
.sp
Documentation by Junio C Hamano and the git\-list <\m[blue]\fBgit@vger\&.kernel\&.org\fR\m[]\&\s-2\u[2]\d\s+2>\&.
.SH "GIT"
.sp
Part of the \fBgit\fR(1) suite
.SH "NOTES"
.IP " 1." 4
gitster@pobox.com
.RS 4
\%mailto:gitster@pobox.com
.RE
.IP " 2." 4
git@vger.kernel.org
.RS 4
\%mailto:git@vger.kernel.org
.RE