Skip to content

Commit c3a8975

Browse files
committed
Add a "bootstrap" script to packages
1 parent 4afef09 commit c3a8975

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@
1313
"clean": "tsc --build --clean",
1414
"dev": "tsc --build --watch",
1515
"lint": "eslint .",
16-
"test": "npm run test --workspace react-native-node-api --workspace cmake-rn --workspace gyp-to-cmake --workspace node-addon-examples"
16+
"test": "npm run test --workspace react-native-node-api --workspace cmake-rn --workspace gyp-to-cmake --workspace node-addon-examples",
17+
"bootstrap": "npm run build && npm run bootstrap --workspaces --if-present"
1718
},
1819
"author": {
1920
"name": "Callstack",

packages/host/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,8 @@
4444
"generate-weak-node-api": "tsx scripts/generate-weak-node-api.ts",
4545
"generate-weak-node-api-injector": "tsx scripts/generate-weak-node-api-injector.ts",
4646
"build-weak-node-api": "npm run generate-weak-node-api && cmake-rn --android --apple --no-auto-link --no-weak-node-api-linkage --xcframework-extension --source ./weak-node-api",
47-
"test": "tsx --test --test-reporter=@reporters/github --test-reporter-destination=stdout --test-reporter=spec --test-reporter-destination=stdout src/node/**/*.test.ts src/node/*.test.ts"
47+
"test": "tsx --test --test-reporter=@reporters/github --test-reporter-destination=stdout --test-reporter=spec --test-reporter-destination=stdout src/node/**/*.test.ts src/node/*.test.ts",
48+
"bootstrap": "npm run copy-node-api-headers && npm run generate-weak-node-api-injector && npm run build-weak-node-api"
4849
},
4950
"keywords": [
5051
"react-native",

packages/node-addon-examples/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@
1313
"build": "tsx scripts/build-examples.mts",
1414
"copy-and-build": "npm run copy-examples && npm run gyp-to-cmake && npm run build",
1515
"verify": "tsx scripts/verify-prebuilds.mts",
16-
"test": "npm run copy-and-build && npm run verify"
16+
"test": "npm run copy-and-build && npm run verify",
17+
"bootstrap": "npm run copy-and-build"
1718
},
1819
"devDependencies": {
1920
"cmake-rn": "*",

0 commit comments

Comments
 (0)