Skip to content

all: clean and build dependencies in prepublishOnly scripts (NFC) #313

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/browser/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"clean": "rimraf \"lib\"",
"format": "prettier --write '**/*.ts'",
"lint": "eslint . --ext .ts",
"prepublishOnly": "cross-env NODE_ENV=production npm run build",
"prepublishOnly": "npm -w ../sdk-core run prepublishOnly && npm run clean && cross-env NODE_ENV=production npm run build",
"watch": "concurrently \"tsc -p tsconfig.build.json --noEmit --watch\" \"rollup -c rollup.config.mjs --watch\"",
"test": "cross-env NODE_OPTIONS=\"$NODE_OPTIONS --experimental-vm-modules\" NODE_NO_WARNINGS=1 NODE_ENV=test jest"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/electron/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
"clean": "rimraf main renderer common",
"format": "prettier --write '**/*.ts'",
"lint": "eslint src --ext .ts",
"prepublishOnly": "cross-env NODE_ENV=production npm run build",
"prepublishOnly": "npm run clean && cross-env NODE_ENV=production npm run build",
"watch": "concurrently \"tsc -p tsconfig.main.json --noEmit --watch\" \"tsc -p tsconfig.renderer.json --noEmit --watch\" \"rollup -c rollup.config.mjs --watch\""
},
"keywords": [
Expand Down
2 changes: 1 addition & 1 deletion packages/nestjs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"clean": "rimraf \"lib\"",
"format": "prettier --write '**/*.ts'",
"lint": "eslint . --ext .ts",
"prepublishOnly": "cross-env NODE_ENV=production npm run build",
"prepublishOnly": "npm run clean && cross-env NODE_ENV=production npm run build",
"watch": "concurrently \"tsc -p tsconfig.build.json --noEmit --watch\" \"rollup -c rollup.config.mjs --watch\"",
"test": "cross-env NODE_OPTIONS=\"$NODE_OPTIONS --experimental-vm-modules\" NODE_NO_WARNINGS=1 NODE_ENV=test jest"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/node/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"clean": "rimraf lib tsconfig.tsbuildinfo",
"format": "prettier --write '**/*.ts'",
"lint": "eslint . --ext .ts",
"prepublishOnly": "cross-env NODE_ENV=production npm run build",
"prepublishOnly": "npm run clean && cross-env NODE_ENV=production npm run build",
"watch": "concurrently \"tsc -p tsconfig.build.json --noEmit --watch\" \"rollup -c rollup.config.mjs --watch\"",
"test": "cross-env NODE_OPTIONS=\"$NODE_OPTIONS --experimental-vm-modules\" NODE_NO_WARNINGS=1 NODE_ENV=test jest"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/react-native/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
"build": "bob build",
"clean": "rimraf \"lib\"",
"format:check": "eslint \"**/*.{js,ts,tsx}\"",
"prepublishOnly": "bob build",
"prepublishOnly": "npm run clean && cross-env NODE_ENV=production bob build",
"test": "cross-env NODE_ENV=test jest"
},
"keywords": [
Expand Down
2 changes: 1 addition & 1 deletion packages/react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"clean": "rimraf \"lib\"",
"format": "prettier --write '**/*.ts'",
"lint": "eslint . --ext .ts",
"prepublishOnly": "cross-env NODE_ENV=production npm run build",
"prepublishOnly": "npm -w ../browser run prepublishOnly && npm run clean && cross-env NODE_ENV=production npm run build",
"watch": "concurrently \"tsc -p tsconfig.build.json --noEmit --watch\" \"rollup -c rollup.config.mjs --watch\"",
"test": "cross-env NODE_OPTIONS=\"$NODE_OPTIONS --experimental-vm-modules\" NODE_NO_WARNINGS=1 NODE_ENV=test jest"
},
Expand Down
3 changes: 2 additions & 1 deletion packages/sdk-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"format": "prettier --write '**/*.ts'",
"lint": "eslint . --ext .ts",
"watch": "concurrently \"tsc -p tsconfig.build.json --noEmit --watch\" \"rollup -c rollup.config.mjs --watch\"",
"test": "cross-env NODE_OPTIONS=\"$NODE_OPTIONS --experimental-vm-modules\" NODE_NO_WARNINGS=1 NODE_ENV=test jest"
"test": "cross-env NODE_OPTIONS=\"$NODE_OPTIONS --experimental-vm-modules\" NODE_NO_WARNINGS=1 NODE_ENV=test jest",
"prepublishOnly": "npm run clean && cross-env NODE_ENV=production npm run build"
},
"repository": {
"type": "git",
Expand Down
2 changes: 1 addition & 1 deletion packages/session-replay/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"format": "prettier --write '**/*.ts'",
"lint": "eslint . --ext .ts",
"watch": "concurrently \"tsc -p tsconfig.build.json --noEmit --watch\" \"rollup -c rollup.config.mjs --watch\"",
"prepublishOnly": "cross-env NODE_ENV=production npm run clean && npm run build",
"prepublishOnly": "npm -w ../sdk-core run prepublishOnly && npm run clean && cross-env NODE_ENV=production npm run build",
"test": "cross-env NODE_OPTIONS=\"$NODE_OPTIONS --experimental-vm-modules\" NODE_NO_WARNINGS=1 NODE_ENV=test jest"
},
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion tools/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"clean": "tsc -b --clean && rimraf \"lib\"",
"format": "prettier --write '**/*.ts'",
"lint": "eslint . --ext .ts",
"prepublishOnly": "cross-env NODE_ENV=production npm run build",
"prepublishOnly": "npm run clean && cross-env NODE_ENV=production npm run build",
"watch": "tsc -w",
"start": "node lib/index.js",
"test": "cross-env NODE_ENV=test jest"
Expand Down
2 changes: 1 addition & 1 deletion tools/rollup-plugin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"build:rollup": "rollup --config rollup.config.js",
"clean": "tsc -b ./tsconfig.build.json --clean && rimraf \"lib\"",
"format": "prettier --write '**/*.ts'",
"prepublishOnly": "cross-env NODE_ENV=production npm run build",
"prepublishOnly": "npm run clean && cross-env NODE_ENV=production npm run build",
"lint": "eslint . --ext .ts",
"watch": "tsc -b ./tsconfig.build.json -w"
},
Expand Down
3 changes: 2 additions & 1 deletion tools/sourcemap-tools/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
"format": "prettier --write '**/*.ts'",
"lint": "eslint . --ext .ts",
"watch": "tsc -w",
"test": "cross-env NODE_ENV=test jest"
"test": "cross-env NODE_ENV=test jest",
"prepublishOnly": "npm run clean && cross-env NODE_ENV=production npm run build"
},
"repository": {
"type": "git",
Expand Down
2 changes: 1 addition & 1 deletion tools/vite-plugin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"build:vite": "vite build --config vite.config.js",
"clean": "tsc -b ./tsconfig.build.json --clean && rimraf \"lib\"",
"format": "prettier --write '**/*.ts'",
"prepublishOnly": "cross-env NODE_ENV=production npm run build",
"prepublishOnly": "npm run clean && cross-env NODE_ENV=production npm run build",
"lint": "eslint . --ext .ts",
"watch": "tsc -b ./tsconfig.build.json -w"
},
Expand Down
2 changes: 1 addition & 1 deletion tools/webpack-plugin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"clean": "tsc -b ./tsconfig.build.json --clean && rimraf \"lib\"",
"format": "prettier --write '**/*.ts'",
"lint": "eslint . --ext .ts",
"prepublishOnly": "cross-env NODE_ENV=production npm run build",
"prepublishOnly": "npm run clean && cross-env NODE_ENV=production npm run build",
"watch": "tsc -b ./tsconfig.build.json -w",
"test:e2e": "npm run test:e2e:webpackv5 && npm run test:e2e:webpackv4",
"test:e2e:webpackv4": "cross-env NODE_ENV=test jest --config ./webpack4.e2e.jest.config.js",
Expand Down