Skip to content

Commit bb3a094

Browse files
authored
[EngSys] add tshy to default catalog and to core packages' dev deps (#36124)
per Pnpm recommendation, dependencies needed for individual packages should be included in their package.json while the global package.json lists tools for mono repo maintenance. This PR adds `tshy` to the default catalog and includes it in core packages' package.json files. Changes to rest of packages and code generator will be in separate pull requests.
1 parent e34e272 commit bb3a094

File tree

19 files changed

+74
-1
lines changed

19 files changed

+74
-1
lines changed

common/tools/dev-tool/src/commands/run/build-package.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import { createPrinter } from "../../util/printer";
66
import path from "node:path";
77
import { spawnSync, StdioOptions } from "node:child_process";
88
import { isWindows } from "../../util/platform";
9+
import { existsSync } from "node:fs";
910

1011
const log = createPrinter("build-package");
1112

@@ -14,7 +15,11 @@ export const commandInfo = makeCommandInfo("build-package", "build a package for
1415
const TSHY_BIN_PATH = path.resolve(__dirname, "..", "..", "..", "node_modules", ".bin", "tshy");
1516

1617
export default leafCommand(commandInfo, async () => {
17-
const commandPath = isWindows() ? `${TSHY_BIN_PATH}.CMD` : TSHY_BIN_PATH;
18+
const centralCommandPath = isWindows() ? `${TSHY_BIN_PATH}.CMD` : TSHY_BIN_PATH;
19+
const localBinPath = path.resolve(process.cwd(), "node_modules", ".bin", "tshy");
20+
const localCommandPath = isWindows() ? `${localBinPath}.CMD` : localBinPath;
21+
const commandPath = existsSync(localCommandPath) ? localCommandPath : centralCommandPath;
22+
1823
log.info(`Building package with tshy from ${commandPath}`);
1924

2025
const proc = spawnSync(commandPath, { stdio: "pipe" as StdioOptions, shell: isWindows() });

pnpm-lock.yaml

Lines changed: 51 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pnpm-workspace.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ catalog:
3131
rimraf: ^6.0.1
3232
tslib: ^2.8.1
3333
tsx: ^4.20.4
34+
tshy: ^3.0.0
3435
typescript: ~5.8.3
3536

3637
# Named catalogs

sdk/core/abort-controller/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@
8484
"@vitest/coverage-istanbul": "catalog:testing",
8585
"eslint": "catalog:",
8686
"playwright": "catalog:testing",
87+
"tshy": "catalog:",
8788
"typescript": "catalog:",
8889
"vitest": "catalog:testing"
8990
},

sdk/core/core-amqp/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,7 @@
9393
"debug": "^4.3.4",
9494
"eslint": "catalog:",
9595
"playwright": "catalog:testing",
96+
"tshy": "catalog:",
9697
"typescript": "catalog:",
9798
"vitest": "catalog:testing",
9899
"ws": "^8.17.0"

sdk/core/core-auth/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@
8080
"@vitest/coverage-istanbul": "catalog:testing",
8181
"eslint": "catalog:",
8282
"playwright": "catalog:testing",
83+
"tshy": "catalog:",
8384
"typescript": "catalog:",
8485
"vitest": "catalog:testing"
8586
},

sdk/core/core-client-rest/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@
8383
"@vitest/coverage-istanbul": "catalog:testing",
8484
"eslint": "catalog:",
8585
"playwright": "catalog:testing",
86+
"tshy": "catalog:",
8687
"typescript": "catalog:",
8788
"vitest": "catalog:testing"
8889
},

sdk/core/core-client/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@
8585
"@vitest/coverage-istanbul": "catalog:testing",
8686
"eslint": "catalog:",
8787
"playwright": "catalog:testing",
88+
"tshy": "catalog:",
8889
"typescript": "catalog:",
8990
"vitest": "catalog:testing"
9091
},

sdk/core/core-http-compat/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@
8080
"@vitest/coverage-istanbul": "catalog:testing",
8181
"eslint": "catalog:",
8282
"playwright": "catalog:testing",
83+
"tshy": "catalog:",
8384
"typescript": "catalog:",
8485
"vitest": "catalog:testing"
8586
},

sdk/core/core-lro/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@
9999
"@vitest/coverage-istanbul": "catalog:testing",
100100
"eslint": "catalog:",
101101
"playwright": "catalog:testing",
102+
"tshy": "catalog:",
102103
"typescript": "catalog:",
103104
"vitest": "catalog:testing"
104105
},

0 commit comments

Comments
 (0)