)]}'
{
  "commit": "ff165f00c1065d94c0bcab8708364e6dc5655f5d",
  "tree": "7262fdc26d7f0416bffeafe8cfa97786b3179037",
  "parents": [
    "b6d4d82bd5a49197d5d2f4f81c08da0d461cfcf1"
  ],
  "author": {
    "name": "Junio C Hamano",
    "email": "gitster@pobox.com",
    "time": "Thu Feb 20 09:34:36 2020 -0800"
  },
  "committer": {
    "name": "Junio C Hamano",
    "email": "gitster@pobox.com",
    "time": "Thu Feb 20 18:05:33 2020 -0800"
  },
  "message": "describe: force long format for a name based on a mislocated tag\n\nAn annotated tag has two names: where it sits in the refs/tags\nhierarchy and the tagname recorded in the \"tag\" field in the object\nitself.  They usually should match.\n\nSince 212945d4 (\"Teach git-describe to verify annotated tag names\nbefore output\", 2008-02-28), a commit described using an annotated\ntag bases its name on the tagname from the object.  While this was a\ndeliberate design decision to make it easier to converse about tags\nwith others, even if the tags happen to be fetched to a different\nname than it was given by its creator, it had one downside.\n\nThe output from \"git describe\", at least in the modern Git, should\nbe usable as an object name to name the exact commit given to the\n\"git describe\" command.  Using the tagname, when two names differ,\nbreaks this property, when describing a commit that is directly\npointed at by such a tag.  An annotated tag Bob made as \"v1.0\" may\nsit at \"refs/tags/v1.0-bob\" in the ref hierarchy, and output from\n\"git describe v1.0-bob^0\" would say \"v1.0\", but there may not be\nany tag at \"refs/tags/v1.0\" locally or there may be another tag that\npoints at a different object.\n\nNote that this won\u0027t be a problem if a commit being described is not\ndirectly pointed at by such a mislocated tag.  In the example in the\nprevious paragraph, describing a commit whose parent is v1.0-bob\nwould result in \"v1.0\" (i.e. the tagname taken from the tag object)\nfollowed by \"-1-gXXXXX\" where XXXXX is the abbreviated object name,\nand a string that ends with \"-g\" followed by a hexadecimal string is\nan object name for the object whose name begins with hexadecimal\nstring (as long as it is unique), so it does not matter if the\nleading part is \"v1.0\" or \"v1.0-bob\".\n\nShow the name in the long format, i.e. with \"-0-gXXXXX\" suffix, when\nthe name we give is based on a mislocated annotated tag to ensure\nthat the output can be used as the object name for the object\noriginally given to the command to fix the issue.\n\nWhile at it, remove an overly cautious dead code to protect against\nan annotated tag object without the tagname.  Such a tag is filtered\nout much earlier in the codeflow, and will not reach this part of\nthe code.\n\nHelped-by: Matheus Tavares \u003cmatheus.bernardino@usp.br\u003e\nHelped-by: Jeff King \u003cpeff@peff.net\u003e\nSigned-off-by: Junio C Hamano \u003cgitster@pobox.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "b6df81d8d0e80e9665ae8f8afcf3cb03d1ae688c",
      "old_mode": 33188,
      "old_path": "builtin/describe.c",
      "new_id": "f71bddff4ab86f87c37075a5712a2480a27d74d1",
      "new_mode": 33188,
      "new_path": "builtin/describe.c"
    },
    {
      "type": "modify",
      "old_id": "45047d0a724e6bb7b59b4b3ae155ced530c660d1",
      "old_mode": 33261,
      "old_path": "t/t6120-describe.sh",
      "new_id": "f22448b6dafea13e9c75f2b9e618b3fa0a25c34f",
      "new_mode": 33261,
      "new_path": "t/t6120-describe.sh"
    }
  ]
}
