diff --git a/packages/core/package.json b/packages/core/package.json index f86d7da..c82fa15 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -47,7 +47,7 @@ "scripts": { "build": "tsc -p tsconfig.json", "clean": "rm -rf dist", - "prepublishOnly": "pnpm run clean && pnpm run build", + "prepublishOnly": "test -f dist/index.js && test -f dist/index.d.ts || (echo 'dist is missing build output; run pnpm build before publishing' >&2 && exit 1)", "test": "pnpm run build && NODE_OPTIONS=--experimental-vm-modules jest", "test:watch": "pnpm run build && NODE_OPTIONS=--experimental-vm-modules jest --watch" }, diff --git a/packages/express/package.json b/packages/express/package.json index ff022b4..8a7df2c 100644 --- a/packages/express/package.json +++ b/packages/express/package.json @@ -39,7 +39,7 @@ "build:types": "tsc -p tsconfig.build.json", "clean": "rm -rf dist", "dev": "tsc --watch", - "prepublishOnly": "pnpm run clean && pnpm run build", + "prepublishOnly": "test -f dist/index.js && test -f dist/index.d.ts || (echo 'dist is missing build output; run pnpm build before publishing' >&2 && exit 1)", "test": "pnpm --filter @seamless-auth/core build && pnpm run build && NODE_OPTIONS=--experimental-vm-modules jest", "test:watch": "pnpm --filter @seamless-auth/core build && pnpm run build && NODE_OPTIONS=--experimental-vm-modules jest --watch" }, diff --git a/packages/fastify/package.json b/packages/fastify/package.json index 86840a6..405f3b3 100644 --- a/packages/fastify/package.json +++ b/packages/fastify/package.json @@ -39,7 +39,7 @@ "build:types": "tsc -p tsconfig.build.json", "clean": "rm -rf dist", "dev": "tsc --watch", - "prepublishOnly": "pnpm run clean && pnpm run build", + "prepublishOnly": "test -f dist/index.js && test -f dist/index.d.ts || (echo 'dist is missing build output; run pnpm build before publishing' >&2 && exit 1)", "test": "pnpm --filter @seamless-auth/core build && pnpm run build && NODE_OPTIONS=--experimental-vm-modules jest", "test:watch": "pnpm --filter @seamless-auth/core build && pnpm run build && NODE_OPTIONS=--experimental-vm-modules jest --watch" },