)]}'
{
  "commit": "4faed34fbc8b599490619cdf310a327c3f3c043f",
  "tree": "e4de2b4f6c1fb4e62405fde4b19c1f0d958049a4",
  "parents": [
    "5372f44b858f6eef834d9632e9960c39c296d448"
  ],
  "author": {
    "name": "Timothée Mazzucotelli",
    "email": "pawamoy@pm.me",
    "time": "Wed Jul 29 09:57:24 2020 +0200"
  },
  "committer": {
    "name": "Anthony Sottile",
    "email": "asottile@umich.edu",
    "time": "Thu Jul 30 11:58:24 2020 -0700"
  },
  "message": "Fix parsing of git output with unusual characters\n\nOn Windows, all files are \"executable\".\nTherefore, to know if a file is supposed to be executed,\nwe check how its attributes were recorded by git:\nwe run a `git ls-files` command in a subprocess.\n\nBy default, this command outputs information\non multiple lines (file and their data separated by newlines).\nWhen a file contains an unusual character,\nthe character is escaped with an integer sequence\n(such as `\\303\\261`), and git wraps the whole filename\nin double-quotes because of the backslashes.\nIt breaks the current code because we try to open\nthe filename containing the double-quotes:\nit doesn\u0027t exist, of course.\n\nInstead of trying to fix this special case by removing\nthe double-quotes, and breaking other cases\n(a double-quote is a valid filename character on Linux),\nwe tell git to separate each item with the null character `\\0`\ninstead of a new line `\\n`, with the option `-z`.\nWith this option, git doesn\u0027t escape unusual characters\nwith integer sequence, so the output is fixed, and we\nparse it by splitting on `\\0` instead of `\\n`.\n\nFixes #508.\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "1c50ea028178dc8a476a9e98ef233b70510fe613",
      "old_mode": 33188,
      "old_path": "pre_commit_hooks/check_executables_have_shebangs.py",
      "new_id": "a02d2a9c5aeedd214c9814e0153d59752fe7dc72",
      "new_mode": 33188,
      "new_path": "pre_commit_hooks/check_executables_have_shebangs.py"
    },
    {
      "type": "modify",
      "old_id": "5895a2ae3801e96333d0af53e841b9b1801cd61f",
      "old_mode": 33188,
      "old_path": "tests/check_executables_have_shebangs_test.py",
      "new_id": "7046081fda09c3f12fc6ac433a31240578a04289",
      "new_mode": 33188,
      "new_path": "tests/check_executables_have_shebangs_test.py"
    }
  ]
}
