chore: organize the lint scripts

This commit is contained in:
Amin Yahyaabadi 2022-08-02 13:12:42 -07:00
parent 97b033e471
commit 17e6b96b64
1 changed files with 11 additions and 8 deletions

View File

@ -17,7 +17,7 @@
"setup_cpp": "./dist/setup_cpp.js"
},
"scripts": {
"build": "shx rm -rf dist/ && shx mkdir ./dist && run-p test.tsc build.parcel copy.matchers",
"build": "shx rm -rf dist/ && shx mkdir ./dist && run-p lint.tsc build.parcel copy.matchers",
"build.docker": "pnpm build && docker build -f ./dev/docker/ubuntu_node.dockerfile -t setup_cpp .",
"build.docker.arch": "pnpm build && docker build -f ./dev/docker/arch_node.dockerfile -t setup_cpp:arch .",
"build.docker.fedora": "pnpm build && docker build -f ./dev/docker/fedora_node.dockerfile -t setup_cpp:fedora .",
@ -27,22 +27,25 @@
"clean": "shx rm -rf .parcel-cache dist exe",
"copy.matchers": "shx cp ./src/gcc/gcc_matcher.json ./dist/ && shx cp ./src/msvc/msvc_matcher.json ./dist && shx cp ./src/python/python_matcher.json ./dist/ && shx cp ./src/llvm/llvm_matcher.json ./dist/ ",
"dev": "cross-env NODE_ENV=development parcel watch",
"format": "prettier --write .",
"lint": "eslint **/*.{ts,tsx,js,jsx,cjs,mjs,json,yaml} --no-error-on-unmatched-pattern --cache --cache-location ./.cache/eslint/ --fix",
"format": "run-s lint.prettier",
"lint": "run-p --aggregate-output --continue-on-error lint.cspell lint.eslint lint.prettier lint.tsc",
"lint.cspell": "cspell lint --no-progress --show-suggestions",
"lint.eslint": "eslint **/*.{ts,tsx,js,jsx,cjs,mjs,json,yaml} --no-error-on-unmatched-pattern --cache --cache-location ./.cache/eslint/ --fix",
"lint.prettier": "prettier --write .",
"lint.tsc": "tsc --noEmit | loose-ts-check",
"pack.exe": "shx rm -rf ./dist/tsconfig.tsbuildinfo && node ./dev/scripts/pack-exe.js",
"prepare": "npm run build",
"start.docker": "docker run -t setup_cpp .",
"start.docker.arch": "docker run -t setup_cpp:arch .",
"start.docker.fedora": "docker run -t setup_cpp:fedora .",
"start.docker.ubuntu": "docker run -t setup_cpp:ubuntu .",
"test": "run-p test.format test.lint test.cspell test.tsc test.unit",
"test.cspell": "cspell lint --no-progress --show-suggestions",
"test": "run-p --aggregate-output --continue-on-error test.lint test.unit",
"test.docker.arch": "docker build -f ./dev/docker/arch_node.dockerfile --target base -t setup_cpp:arch-base . && container-structure-test test --image setup_cpp:arch-base --config ./dev/container-tests/arch.yml",
"test.docker.fedora": "docker build -f ./dev/docker/fedora_node.dockerfile --target base -t setup_cpp:fedora-base . && container-structure-test test --image setup_cpp:fedora-base --config ./dev/container-tests/fedora.yml",
"test.docker.ubuntu": "docker build -f ./dev/docker/ubuntu_node.dockerfile --target base -t setup_cpp:ubuntu-base . && container-structure-test test --image setup_cpp:ubuntu-base --config ./dev/container-tests/ubuntu.yml",
"test.format": "prettier . --check",
"test.lint": "eslint **/*.{ts,tsx,js,jsx,cjs,mjs,json,yaml} --no-error-on-unmatched-pattern --cache --cache-location ./.cache/eslint/",
"test.tsc": "tsc --noEmit | loose-ts-check",
"test.lint": "run-p --aggregate-output --continue-on-error lint.cspell test.lint.eslint test.lint.prettier lint.tsc",
"test.lint.eslint": "eslint **/*.{ts,tsx,js,jsx,cjs,mjs,json,yaml} --no-error-on-unmatched-pattern --cache --cache-location ./.cache/eslint/",
"test.lint.prettier": "prettier . --check",
"test.unit": "jest --runInBand"
},
"prettier": "prettier-config-atomic",