{"thread":{"id":"26355","subject":"Why git tags are there in git?","startedAt":"2011-01-28T11:37:56Z","lastAt":"2011-01-29T17:17:51Z","messageCount":5,"participants":["vikram2rhyme","L. Alberto Giménez","Gabriel Filion","Konstantin Khomoutov","Enrico Weigelt"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"159977","messageId":"1296214676536-5969544.post@n2.nabble.com","threadId":"26355","inReplyTo":null,"subject":"Why git tags are there in git?","fromName":"vikram2rhyme","fromEmail":"vikram2rhyme@gmail.com","sentAt":"2011-01-28T11:37:56Z","receivedAt":"2011-01-28T11:37:56Z","isPatch":false,"sender":{"key":"vikram2rhyme@gmail.com","avatar":null},"body":"\nHello friends\nI am wondering why the tags are there in git. As they are just pointer to\nthe commit\nwe can refer those commit by SHA sum only then why tagging? Moreover a\ncommit can\nbe tagged more than once that result in multiple tags pointing to the same\npoint in the history.\nIs this a design flaw?\n-- \nView this message in context: http://git.661346.n2.nabble.com/Why-git-tags-are-there-in-git-tp5969544p5969544.html\nSent from the git mailing list archive at Nabble.com.\n"},{"id":"159981","messageId":"4D42B623.5060709@sysvalve.es","threadId":"26355","inReplyTo":"1296214676536-5969544.post@n2.nabble.com","subject":"Re: Why git tags are there in git?","fromName":"L. Alberto Giménez","fromEmail":"agimenez@sysvalve.es","sentAt":"2011-01-28T12:27:15Z","receivedAt":"2011-01-28T12:27:15Z","isPatch":false,"sender":{"key":"agimenez@sysvalve.es","avatar":null},"body":"On 28/01/2011 12:37, vikram2rhyme wrote:\n>\n> Hello friends\n> I am wondering why the tags are there in git. As they are just pointer to\n> the commit\n> we can refer those commit by SHA sum only then why tagging?\n\nHi, I tend to find easier \"release-v1\" than 2cff0e391ab127ae...\n\nRegards,\nL. Alberto Giménez\n"},{"id":"159986","messageId":"4D42DABA.5060603@gmail.com","threadId":"26355","inReplyTo":"4D42B623.5060709@sysvalve.es","subject":"Re: Why git tags are there in git?","fromName":"Gabriel Filion","fromEmail":"lelutin@gmail.com","sentAt":"2011-01-28T15:03:22Z","receivedAt":"2011-01-28T15:03:22Z","isPatch":false,"sender":{"key":"lelutin@gmail.com","avatar":"https://avatars.githubusercontent.com/u/108728?v=4"},"body":"On 11-01-28 07:27 AM, \"L. Alberto Giménez\" wrote:\n> On 28/01/2011 12:37, vikram2rhyme wrote:\n>>\n>> Hello friends\n>> I am wondering why the tags are there in git. As they are just pointer to\n>> the commit\n>> we can refer those commit by SHA sum only then why tagging?\n> \n> Hi, I tend to find easier \"release-v1\" than 2cff0e391ab127ae...\n> \n\nIn general, tags are used for marking a point in time. That marker won't\nmove, whereas branches can move with time.\n\nFor example, in most projects tags are used to make it easier to refer\nto commits that mark official releases. In git.git (git's own\nrepository), the tag v1.7.3.5 points to the release with the same number.\n\n-- \nGabriel Filion\n"},{"id":"159989","messageId":"20110128190628.f507599e.kostix@domain007.com","threadId":"26355","inReplyTo":"1296214676536-5969544.post@n2.nabble.com","subject":"Re: Why git tags are there in git?","fromName":"Konstantin Khomoutov","fromEmail":"flatworm@users.sourceforge.net","sentAt":"2011-01-28T16:06:28Z","receivedAt":"2011-01-28T16:06:28Z","isPatch":false,"sender":{"key":"flatworm@users.sourceforge.net","avatar":null},"body":"On Fri, 28 Jan 2011 03:37:56 -0800 (PST)\nvikram2rhyme <vikram2rhyme@gmail.com> wrote:\n\n> I am wondering why the tags are there in git. As they are just\n> pointer to the commit\n> we can refer those commit by SHA sum only then why tagging? Moreover a\n> commit can\n> be tagged more than once that result in multiple tags pointing to the\n> same point in the history.\n> Is this a design flaw?\n\nAmending what other commenters said, I should note that beyond regular\ntags which just provide human-readable names to objects, there exist\nso-called \"annotated tags\" which are tags with descriptive messages\ncontained in them, which can be used as a side-channel to provide\nadditional information for commits, and also to digitally sign a line\nof history to which such a tag is attached.\n\nAlso note that a tag can be attached to any object in a Git database,\nnot necessarily to a commit. This can be occasionally useful.\n"},{"id":"160029","messageId":"20110129171750.GA602@nibiru.local","threadId":"26355","inReplyTo":"1296214676536-5969544.post@n2.nabble.com","subject":"Re: Why git tags are there in git?","fromName":"Enrico Weigelt","fromEmail":"weigelt@metux.de","sentAt":"2011-01-29T17:17:51Z","receivedAt":"2011-01-29T17:17:51Z","isPatch":false,"sender":{"key":"weigelt@metux.de","avatar":null},"body":"* vikram2rhyme <vikram2rhyme@gmail.com> wrote:\n\nHi,\n\n> I am wondering why the tags are there in git. As they are just\n> pointer to the commit we can refer those commit by SHA sum only\n> then why tagging? Moreover a commit can be tagged more than once\n> that result in multiple tags pointing to the same point in the history.\n> Is this a design flaw?\n\nNo, it's an important design aspect.\n\nTag references (not to be mixed up w/ tag objects) are very useful\nto add a conveniently named pointer to some object (not necessarily\na commit), so humans as well as programs can easily find them.\n\nFor example, in my OSS-QM repositories [1], I have some robots\nimporting releases (sometimes from upstream's git repos, sometimes\nfrom foreign VCSs, tarballs or even distro packages) and tag\nthem into a normalized namespace, so automatic systems (eg. my\nBriegel buildsystem) can easily fetch sourcetrees from there\nw/o further manual tweaking.\n\n\ncu\n\n[1] http://www.metux.de/download/oss-qm/normalized_repository.pdf\n-- \n----------------------------------------------------------------------\n Enrico Weigelt, metux IT service -- http://www.metux.de/\n\n phone:  +49 36207 519931  email: weigelt@metux.de\n mobile: +49 151 27565287  icq:   210169427         skype: nekrad666\n----------------------------------------------------------------------\n Embedded-Linux / Portierung / Opensource-QM / Verteilte Systeme\n----------------------------------------------------------------------\n"}]}