diff --git a/build-target.sh b/build-target.sh new file mode 100755 index 0000000..f09019d --- /dev/null +++ b/build-target.sh @@ -0,0 +1,10 @@ +#!/bin/bash + +version=$(jq -r '.version' package.json) +echo "Building version $version" + +pnpm build +zip -r "chrome_$version.zip" extension +pnpm build-edge +zip -r "edge_$version.zip" extension + diff --git a/package.json b/package.json index a41e337..dc80f56 100644 --- a/package.json +++ b/package.json @@ -31,7 +31,8 @@ "clean": "rimraf -rf ./extension ./dist ./*.zip ./*.crx", "reinstall": "rimraf -rf ./node_modules && pnpm", "prepare": "husky install", - "test-ext": "jest --config ./jest.config.js" + "test-ext": "jest --config ./jest.config.js", + "package": "./build-target.sh" }, "lint-staged": { "*.{ts,tsx,js}": [