From b81cf907ef5c123d82106c8ff4e734668142b81d Mon Sep 17 00:00:00 2001 From: Peter Somogyvari Date: Wed, 4 Aug 2021 11:48:28 -0700 Subject: [PATCH] build(package.json): add reset script that git cleans prior to configure Why though? This is designed to eliminate possible build issues that arise because of leftover code files somehow lurking around the project directory structure that are being ignored by git and therefore lulling a contributor to thinking that since VSCode shows no index/staged changes the project is in a clean slate and the build should pass all the same. The reset script in essence is a softer version of going all out, deleting your entire project directory and cloning it from scratch which is a lot more effort than just running the reset script added here that has a good chance of fixing the same problems as the hard resetting if re-clone would fix. Signed-off-by: Peter Somogyvari --- package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/package.json b/package.json index a678f712ce..7a9bc0a93e 100644 --- a/package.json +++ b/package.json @@ -9,6 +9,7 @@ ], "scripts": { "run-ci": "./tools/ci.sh", + "reset": "git clean -f -X && yarn run configure", "configure": "yarn install --frozen-lockfile --non-interactive && yarn run build:dev:backend", "install-yarn": "npm install --global yarn@1.19.0", "custom-checks": "ts-node ./tools/custom-checks/run-custom-checks.ts",