{"thread":{"id":"29613","subject":"git cherry doesn't list a merge commit","startedAt":"2012-02-13T15:17:10Z","lastAt":"2012-02-13T18:57:17Z","messageCount":2,"participants":["Tajti Ákos","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"184569","messageId":"4F392976.9070009@intland.com","threadId":"29613","inReplyTo":null,"subject":"git cherry doesn't list a merge commit","fromName":"Tajti Ákos","fromEmail":"akos.tajti@intland.com","sentAt":"2012-02-13T15:17:10Z","receivedAt":"2012-02-13T15:17:10Z","isPatch":false,"sender":{"key":"akos.tajti@intland.com","avatar":null},"body":"Dear List,\n\nI have a question/misunderstanding about 'git cherry'. The scenario is \nthe following:\nI have two repositories (two forks of the same parent repo): A and B. I \ncreated a commit in A, then pulled B to A and finally made an other \ncommit in A. This resulted the following commits:\n\n-----\ncommit f6afabb0a734843d5d122b612f0701d27b178e42\nAuthor: akostajti <akos.tajti@intland.com>\nDate: Mon Feb 13 15:59:51 2012 +0100\n\nmodified a\n\ncommit 4ec4d59f632b93456890db139125419d16a10807\nMerge: a73e884 2a483e8\nAuthor: akostajti <akos.tajti@intland.com>\nDate: Mon Feb 13 15:59:34 2012 +0100\n\nMerge branch 'master' of http://localhost:3180/git/first-60-project\n\ncommit a73e884d2dadf29898c2d6b665ed79d352422d26\nAuthor: akostajti <akos.tajti@intland.com>\nDate: Mon Feb 13 15:58:48 2012 +0100\n\nhkl\n-----\n\nNow If I fetch B to A and run 'git cherry FETCH_HEAD master' I get only \ntwo changeset ids:\n+ a73e884d2dadf29898c2d6b665ed79d352422d26\n+ f6afabb0a734843d5d122b612f0701d27b178e42\n\nHowever, the manual of git cherry says:\n\"*Every* commit that doesn’t exist in the <upstream> branch has its id \n(sha1) reported, prefixed by a symbol. The ones that have equivalent \nchange already in the <upstream> branch are prefixed with a minus (-) sign\"\n\nIn my understanding this means that the merge commit \n(4ec4d59f632b93456890db139125419d16a10807) should be also listed by \ncherry, because it doesn't exist in the upstream. Am I doing something \nwrong? How can I ge git cherry work as I expect?\n\nThanks in advance,\nÁkos Tajti\n"},{"id":"184584","messageId":"7vaa4mfto2.fsf@alter.siamese.dyndns.org","threadId":"29613","inReplyTo":"4F392976.9070009@intland.com","subject":"Re: git cherry doesn't list a merge commit","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2012-02-13T18:57:17Z","receivedAt":"2012-02-13T18:57:17Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Tajti Ákos <akos.tajti@intland.com> writes:\n\n> However, the manual of git cherry says:\n> \"*Every* commit that doesn’t exist in the <upstream> branch has its\n> id (sha1) reported, prefixed by a symbol. The ones that have\n> equivalent change already in the <upstream> branch are prefixed with a\n> minus (-) sign\"\n\nThe sole purpose of the command is to decide which commits in the existing\nhistory to run \"format-patch\" on to feed the output to \"am\" to update the\nother history, and it was clear for both readers and the author of the\ndocumentation that a \"commit\" meant a \"non-merge commit\" in that context.\n\nA patch to rephrase it to \"every non-merge commit\" for clarity may not be\nuseless, though.\n"}]}