package.json 999 Bytes
Newer Older
1 2 3
{
  "lint-staged": {
    "*.json": [
4
      "./format-json"
5
    ],
6
    "{component,software,stack}/**": [
7 8
      "python3 -c 'import sys, os.path, subprocess; [subprocess.check_call((\"./update-hash\", buildout_hash)) for buildout_hash in { os.path.join(os.path.dirname(staged), \"buildout.hash.cfg\") for staged in sys.argv[1:]} if os.path.exists(buildout_hash)]'",
      "python3 -c 'import sys, os.path, subprocess; [subprocess.check_call((\"git\", \"add\", buildout_hash)) for buildout_hash in { os.path.join(os.path.dirname(staged), \"buildout.hash.cfg\") for staged in sys.argv[1:]} if os.path.exists(buildout_hash)]'"
9 10
    ]
  },
11 12 13 14 15
  "devDependencies": {
    "husky": "^7.0.0",
    "lint-staged": "^12.1.2"
  },
  "scripts": {
16
    "prepare": "husky install && git config merge.tool update-hash-mergetool && git config mergetool.update-hash-mergetool.cmd './update-hash-mergetool \"$BASE\" \"$LOCAL\" \"$REMOTE\" \"$MERGED\"' && git config mergetool.update-hash-mergetool.trustExitCode true"
17 18
  }
}