)]}'
{
  "commit": "c3e2d18996e4ef92f37bf56b2fefe2124d26659e",
  "tree": "91b0fe91d2ffc0686f5f4bb17ba8b6a161cb560d",
  "parents": [
    "b3b8ceb48b7d75631a8638f1dc6ccdf7f1b53888"
  ],
  "author": {
    "name": "Junio C Hamano",
    "email": "gitster@pobox.com",
    "time": "Wed Jun 19 10:54:00 2013 -0700"
  },
  "committer": {
    "name": "Junio C Hamano",
    "email": "gitster@pobox.com",
    "time": "Wed Jun 19 10:54:00 2013 -0700"
  },
  "message": "setup_reflog_action: document the rules for using GIT_REFLOG_ACTION\n\nThe set_reflog_action helper (in git-sh-setup) is designed to be\nused once at the very top of a program, like this in \"git am\", for\nexample:\n\n\tset_reflog_action am\n\nThe helper function sets the given string to GIT_REFLOG_ACTION only\nwhen GIT_REFLOG_ACTION is not yet set.  Thanks to this, \"git am\",\nwhen run as the top-level program, will use \"am\" in GIT_REFLOG_ACTION\nand the reflog entries made by whatever it does will record the\nupdates of refs done by \"am\".\n\nBecause of the conditional assignment, when \"git am\" is run as a\nsubprogram (i.e. an implementation detail) of \"git rebase\" that\nalready sets GIT_REFLOG_ACTION to its own name, the call in \"git am\"\nto the helper function at the beginning will *not* have any effect.\n\nSo \"git rebase\" can do this:\n\n\tset_reflog_action rebase\n\t... do its own preparation, like checking out \"onto\" commit\n        ... decide to do \"format-patch\" to \"am\" pipeline\n        \tgit format-patch --stdout \u003embox\n\t\tgit am mbox\n\nand the reflog entries made inside \"git am\" invocation will say\n\"rebase\", not \"am\".\n\nCalls to \"git\" commands that update refs would use GIT_REFLOG_ACTION\nto record who did that update.  Most such calls in scripted Porcelains\ndo not define custom reflog message and rely on GIT_REFLOG_ACTION to\ncontain its (or its caller\u0027s, when it is called as a subprogram) name.\n\nIf a scripted Porcelain wants to record a custom reflog message for\na single invocation of \"git\" command (e.g. when \"git rebase\" uses\n\"git checkout\" to detach HEAD at the commit a series is to be\nreplayed on), it needs to set GIT_REFLOG_ACTION to the custom\nmessage and export it while calling the \"git\" command, but such an\nassignment must be restricted to that single \"git\" invocation and\nshould not be left behind to affect later codepath.\n\nDocument the rules to avoid future confusion.\n\nSigned-off-by: Junio C Hamano \u003cgitster@pobox.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "6a9f66d1d920f0bfce1db823e2de3f696ce99f23",
      "old_mode": 33188,
      "old_path": "Documentation/git-sh-setup.txt",
      "new_id": "79a88b92054234b0cc50e6ce8872f44979904564",
      "new_mode": 33188,
      "new_path": "Documentation/git-sh-setup.txt"
    },
    {
      "type": "modify",
      "old_id": "9e302b0a60552c4297cb94018dad49169505bd35",
      "old_mode": 33188,
      "old_path": "Documentation/git.txt",
      "new_id": "78db385fb73c0f71db68516a63e857b9f0d194e0",
      "new_mode": 33188,
      "new_path": "Documentation/git.txt"
    },
    {
      "type": "modify",
      "old_id": "9cfbe7f1435e073eeb39ab2190eda2d2dda300a5",
      "old_mode": 33188,
      "old_path": "git-sh-setup.sh",
      "new_id": "53ab0684f27f071b802abac26f62543ab27fae92",
      "new_mode": 33188,
      "new_path": "git-sh-setup.sh"
    }
  ]
}
