Skip to content
代码片段 群组 项目
package.json 10.2 KB
Newer Older
Jing Teng's avatar
Jing Teng 已提交
  "type": "commonjs",
  "name": "zap",
  "version": "0.99.6",
  "description": "Configuration tool for the Zigbee Cluster Library",
  "productName": "zap",
  "cordovaId": "",
  "capacitorId": "",
  "author": {
    "name": "Silicon Labs",
    "email": "zap_support@silabs.com",
  "private": true,
  "main": "src-electron/main-process/electron-main.js",
Jing Teng's avatar
Jing Teng 已提交
    "wp": "npm run version-stamp && webpack -c webpack.main.config.js --progress",
    "lic": "node src-script/license-check.js --production",
    "lint": "eslint --ext .js,.vue src src-electron src-shared src-script test",
    "lintfix": "eslint --fix --ext .js,.vue src src-electron src-shared src-script test",
    "electron-build-dmg": "node src-script/build-dmg.js",
    "test": "node src-script/zap-versionstamp.js && jest --reporters=jest-junit --reporters=default --updateSnapshot",
    "test:unit": "jest --updateSnapshot",
    "test:unit:verbose": "jest --updateSnapshot --verbose false",
    "test:unit:coverage": "jest --coverage",
    "test:unit:watch": "jest --watch",
    "test:unit:watchAll": "jest --watchAll",
    "postinstall": "electron-builder install-app-deps && husky install",
Jing Teng's avatar
Jing Teng 已提交
    "wpzap": "quasar build && npm run wp && npx electron ./dist/electron-main.js",
    "zap": "node src-script/zap-start.js --logToStdout --gen ./test/gen-template/zigbee/gen-templates.json",
    "zap-dev": "npm run build-spa && quasar dev -m electron",
    "zap-devserver": "node src-script/zap-start.js server --allowCors --logToStdout --gen ./test/gen-template/zigbee/gen-templates.json --reuseZapInstance",
    "server": "node src-script/zap-start.js server --logToStdout --gen ./test/gen-template/zigbee/gen-templates.json --reuseZapInstance",
    "stop": "node src-script/zap-start.js stop --reuseZapInstance",
    "status": "node src-script/zap-start.js status --reuseZapInstance",
    "zaphelp": "node src-script/zap-start.js --help",
    "zap-dotdot": "node src-script/zap-start.js --logToStdout --zcl ./zcl-builtin/dotdot/library.xml",
    "build-spa": "node src-script/build-spa.js",
    "renderer-api-regen": "node src-script/renderer-api-regen.js",
    "doc": "jsdoc src-electron src-shared -r -u docs -d ./generated-html/ README.md",
    "apidoc": "jsdoc2md src-shared/**/*.js src-electron/**/*.js > docs/api.md",
    "format-code": "pretty-quick",
    "self-check": "node src-script/zap-start.js selfCheck -g ./test/gen-template/zigbee/gen-templates.json",
    "version-stamp": "node src-script/zap-versionstamp.js",
    "refresh-zap": "node src-script/zap-convert.js -z zcl-builtin/silabs/zcl.json test/resource/three-endpoint-device.zap -g test/gen-template/zigbee/gen-templates.json -o test/resource/three-endpoint-device.zap",
    "gen": "node src-script/zap-generate.js --stateDirectory ~/.zap/gen -z ./zcl-builtin/silabs/zcl.json -g ./test/gen-template/zigbee/gen-templates.json -i ./test/resource/three-endpoint-device.zap -o ./tmp",
    "gen2": "node src-script/zap-generate.js -z ./zcl-builtin/silabs/zcl.json -g ./test/gen-template/zigbee/gen-templates.json -i ./test/resource/generation-test-file-1.zap -o ./tmp",
    "gen3": "node src-script/zap-generate.js --stateDirectory ~/.zap/gen3 -z ./zcl-builtin/dotdot/library.xml -g ./test/gen-template/zigbee/gen-templates.json -i ./test/resource/generation-test-file-1.zap -o ./tmp",
    "genmatter": "node src-script/zap-generate.js --stateDirectory ~/.zap/genmatter -z ./zcl-builtin/matter/zcl.json -g ./test/gen-template/matter/gen-test.json -i ./test/resource/matter-test.zap -o ./tmp",
    "gentest": "node src-script/zap-generate.js --stateDirectory ~/.zap/gentest -z ./zcl-builtin/silabs/zcl.json -g ./test/gen-template/test/gen-test.json -o ./tmp",
    "gendotdot": "node src-script/zap-generate.js -z ./zcl-builtin/dotdot/library.xml -g ./test/gen-template/dotdot/dotdot-templates.json -o ./tmp",
    "genblank": "node src-script/zap-generate.js -z ./zcl-builtin/silabs/zcl.json -g ./test/gen-template/zigbee/gen-templates.json -o ./tmp",
    "convert": "node src-script/zap-convert.js -o {basename}.zap -z ./zcl-builtin/silabs/zcl.json -g test/gen-template/zigbee/gen-templates.json ./test/resource/isc/*.isc ./test/resource/*.zap",
    "convert-dl": "node src-script/zap-convert.js -o {basename}.zap -z ./zcl-builtin/silabs/zcl.json -g test/gen-template/zigbee/gen-templates.json ./test/resource/isc/ha-door-lock.isc",
    "post-import": "node src-script/zap-start.js convert --postImportScript test/resource/test-script.js test/resource/three-endpoint-device.zap -o test.zap",
    "analyze": "node src-script/zap-start.js analyze -z ./zcl-builtin/silabs/zcl.json -g ./test/gen-template/zigbee/gen-templates.json ./test/resource/three-endpoint-device.zap -o ./tmp",
    "pack": "node src-script/build-spa.js && electron-builder --dir",
    "dist": "electron-builder",
    "dist-all": "electron-builder -mwl",
    "publish-linux": "electron-builder -l -p always",
    "dist-win": "electron-builder -w",
    "dist-mac": "electron-builder -m",
    "apack:win": "cp apack.json dist/win-unpacked/apack.json && cd dist/win-unpacked && zip -r ../zap_apack_win * && cd -",
    "apack:mac": "cp apack.json dist/mac/apack.json && cd dist/mac && zip -ry ../zap_apack_mac * && cd -",
    "apack:linux": "cp apack.json dist/linux-unpacked/apack.json && cd dist/linux-unpacked && zip -r ../zap_apack_linux *",
    "linuxpack-ui": "./dist/linux-unpacked/zap --zclProperties zcl-builtin/silabs/zcl-test.properties --genTemplateJson test/gen-template/zigbee/gen-templates.json",
    "linuxpack-check": "./dist/linux-unpacked/zap selfCheck --zclProperties zcl-builtin/silabs/zcl-test.properties --genTemplateJson test/gen-template/zigbee/gen-templates.json",
    "linuxpack-gen": "./dist/linux-unpacked/zap generate --noUi --noServer --zclProperties zcl-builtin/silabs/zcl-test.properties --genTemplateJson test/gen-template/zigbee/gen-templates.json --output tmp",
    "linuxpack-help": "./dist/linux-unpacked/zap -?",
    "helper-api-baseline": "node src-script/gen-helper-api.js && pretty-quick"
  },
  "dependencies": {
Jing Teng's avatar
Jing Teng 已提交
  },
  "devDependencies": {
Jing Teng's avatar
Jing Teng 已提交
  },
  "engines": {
    "node": ">= 8.9.0",
    "npm": ">= 5.6.0",
    "yarn": ">= 1.6.0"
  },
  "browserslist": [
    "last 1 version, not dead, ie >= 11"
  ],
  "husky": {
    "hooks": {
      "pre-commit": "pretty-quick --staged && jsdoc src-electron src-shared -r -d ./generated-html/ && eslint --ext .js,.vue src src-electron src-shared src-script test"
    }
  },
  "prettier": {
    "semi": false,
    "singleQuote": true,
    "printWidth": 80,
    "tabWidth": 2,
    "useTabs": false,
    "arrowParens": "always"
  },
  "build": {
    "appId": "zap.id",
    "mac": {
      "category": "public.app-category.developer-tools",
      "darkModeSupport": true,
    "linux": {
      "target": [
        "snap",
        "AppImage",
        "deb",
Jing Teng's avatar
Jing Teng 已提交
    "win": {
      "target": [
        "portable"
      ]
    },
    "directories": {
      "buildResources": "resource-build",
      "output": "dist"
    },
    "nodeGypRebuild": false,
    "npmRebuild": true,
    "files": [
      "**/*",
      "!test/**/*",
      "!tmp/**/*",
      "!**/node_modules/*/{CHANGES.md,History.md,CONTRIBUTING.md,CHANGELOG.md,README.md,README.md~,HISTORY.md,README,readme.md,readme}",
      "!**/node_modules/*/{test,__tests__,tests,powered-test,example,examples}",
      "!**/node_modules/*.d.ts",
      "!**/node_modules/.bin",
      "!**/*.{iml,o,hprof,orig,pyc,pyo,rbc,swp,csproj,sln,xproj}",
      "!.editorconfig",
      "!**/._*",
      "!**/{.DS_Store,.git,.hg,.svn,CVS,RCS,SCCS,.gitignore,.gitattributes}",
      "!**/{__pycache__,thumbs.db,.flowconfig,.idea,.vs,.nyc_output}",
      "!**/{appveyor.yml,.travis.yml,circle.yml}",
      "!**/{npm-debug.log,yarn.lock,.yarn-integrity,.yarn-metadata.json}",
      "!generated-html/**/*",
      "!docs/**/*",
      "!.github/**/*",
      "!**/node_modules/sqlite3/build/Release/**/*",
      "!quasar*",
      "!test.*",
      "!src-script/**/*"