{"thread":{"id":"49315","subject":"with git 1.8.3.1 get only merged tags","startedAt":"2018-09-11T10:43:28Z","lastAt":"2018-09-14T10:48:08Z","messageCount":5,"participants":["Michal Novotny","Jeff King","Ævar Arnfjörð Bjarmason"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"357858","messageId":"CANT8FXRbep_32-eeMSa0C1e6q6MUvFddgTUiUgqv54J-2c+iXg@mail.gmail.com","threadId":"49315","inReplyTo":null,"subject":"with git 1.8.3.1 get only merged tags","fromName":"Michal Novotny","fromEmail":"clime@redhat.com","sentAt":"2018-09-11T10:43:15Z","receivedAt":"2018-09-11T10:43:28Z","isPatch":false,"sender":{"key":"clime@redhat.com","avatar":null},"body":"Hello,\n\nI need to emulate git tag --merged with very old git 1.8.3.1. Is that\nsomehow possible?\nI am looking for a bash function that would take what git 1.8.3.1\noffers and return only the tags accessible from the current branch\ntip. Could you, please, give me at least a hint how this could be\ndone?\n\nThank you\nclime\n"},{"id":"357895","messageId":"20180911190519.GA8396@sigill.intra.peff.net","threadId":"49315","inReplyTo":"CANT8FXRbep_32-eeMSa0C1e6q6MUvFddgTUiUgqv54J-2c+iXg@mail.gmail.com","subject":"Re: with git 1.8.3.1 get only merged tags","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2018-09-11T19:05:19Z","receivedAt":"2018-09-11T19:05:23Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Tue, Sep 11, 2018 at 12:43:15PM +0200, Michal Novotny wrote:\n\n> I need to emulate git tag --merged with very old git 1.8.3.1. Is that\n> somehow possible?\n> I am looking for a bash function that would take what git 1.8.3.1\n> offers and return only the tags accessible from the current branch\n> tip. Could you, please, give me at least a hint how this could be\n> done?\n\nThis is not particularly fast, but it should work:\n\n  git for-each-ref refs/tags |\n  cut -f2 |\n  while read tag; do\n    test \"$(git merge-base $tag HEAD)\" = \\\n         \"$(git rev-parse $tag^{commit})\" && echo $tag\n  done\n\n-Peff\n"},{"id":"358039","messageId":"CANT8FXSu9rqbw5D05LfcrD1GpenFGdB6TAcaHJGFJiouzctxJQ@mail.gmail.com","threadId":"49315","inReplyTo":"20180911190519.GA8396@sigill.intra.peff.net","subject":"Re: with git 1.8.3.1 get only merged tags","fromName":"Michal Novotny","fromEmail":"clime@redhat.com","sentAt":"2018-09-13T08:36:30Z","receivedAt":"2018-09-13T08:36:44Z","isPatch":false,"sender":{"key":"clime@redhat.com","avatar":null},"body":"On Tue, Sep 11, 2018 at 9:05 PM Jeff King <peff@peff.net> wrote:\n>\n> On Tue, Sep 11, 2018 at 12:43:15PM +0200, Michal Novotny wrote:\n>\n> > I need to emulate git tag --merged with very old git 1.8.3.1. Is that\n> > somehow possible?\n> > I am looking for a bash function that would take what git 1.8.3.1\n> > offers and return only the tags accessible from the current branch\n> > tip. Could you, please, give me at least a hint how this could be\n> > done?\n>\n> This is not particularly fast, but it should work:\n>\n>   git for-each-ref refs/tags |\n>   cut -f2 |\n>   while read tag; do\n>     test \"$(git merge-base $tag HEAD)\" = \\\n>          \"$(git rev-parse $tag^{commit})\" && echo $tag\n>   done\n\nThat works for me. Thank you a lot for help!\n\nclime\n\n>\n> -Peff\n"},{"id":"358043","messageId":"87lg85ljsc.fsf@evledraar.gmail.com","threadId":"49315","inReplyTo":"CANT8FXRbep_32-eeMSa0C1e6q6MUvFddgTUiUgqv54J-2c+iXg@mail.gmail.com","subject":"Re: with git 1.8.3.1 get only merged tags","fromName":"Ævar Arnfjörð Bjarmason","fromEmail":"avarab@gmail.com","sentAt":"2018-09-13T11:27:15Z","receivedAt":"2018-09-13T11:27:20Z","isPatch":false,"sender":{"key":"avarab@gmail.com","avatar":"https://avatars.githubusercontent.com/u/45301?v=4"},"body":"\nOn Tue, Sep 11 2018, Michal Novotny wrote:\n\n> I need to emulate git tag --merged with very old git 1.8.3.1. Is that\n> somehow possible?\n> I am looking for a bash function that would take what git 1.8.3.1\n> offers and return only the tags accessible from the current branch\n\nJeff answer the question you had, but I just have one of my own: Is\nRedHat stuck on 1.8-era git in some release it's still maintaining, does\nthis mean that e.g. you're still backporting security fixes to this\n2012-era release?\n"},{"id":"358116","messageId":"CANT8FXQrrgj=iVV0tX=MO9LH+=joQUfJmtDeACwyQjNT93e0aw@mail.gmail.com","threadId":"49315","inReplyTo":"87lg85ljsc.fsf@evledraar.gmail.com","subject":"Re: with git 1.8.3.1 get only merged tags","fromName":"Michal Novotny","fromEmail":"clime@redhat.com","sentAt":"2018-09-14T10:47:53Z","receivedAt":"2018-09-14T10:48:08Z","isPatch":false,"sender":{"key":"clime@redhat.com","avatar":null},"body":"On Thu, Sep 13, 2018 at 1:27 PM Ævar Arnfjörð Bjarmason\n<avarab@gmail.com> wrote:\n>\n>\n> On Tue, Sep 11 2018, Michal Novotny wrote:\n>\n> > I need to emulate git tag --merged with very old git 1.8.3.1. Is that\n> > somehow possible?\n> > I am looking for a bash function that would take what git 1.8.3.1\n> > offers and return only the tags accessible from the current branch\n>\n> Jeff answer the question you had, but I just have one of my own: Is\n> RedHat stuck on 1.8-era git in some release it's still maintaining, does\n> this mean that e.g. you're still backporting security fixes to this\n> 2012-era release?\n\nYes, that's exactly the case with RHEL-7.\n\nclime\n"}]}