Skip to content
Source
Sign inSign up
pingdotgg/t3code
Open History to see the last commit

.pnpmfile.cjs

30 lines1.3 KB

1// Windows WSL dev mode runs the server under Linux from the same node_modules
2// as the Windows client, so Windows installs also need Linux x64 glibc native
3// modules. Other platforms install only their own binaries; setting this
4// everywhere added ~2.2 GB of foreign binaries to every macOS install.
5// Release scripts stage their own installs with explicit architectures.
6module.exports = {
7 hooks: {
8 // `typescript` is @tsc-rs/typescript (the catalog entry). Its npm version (0.8.x) is outside
9 // vite-plus-core's typescript peer range, so pnpm gave the vite-plus that @effect/vitest
10 // imports apps/marketing's typescript@6.0.3 instead, and tests loaded a second vitest.
11 readPackage(pkg) {
12 if (pkg.name === "@voidzero-dev/vite-plus-core" && pkg.peerDependencies?.typescript) {
13 pkg.peerDependencies.typescript = "*";
14 }
15 return pkg;
16 },
17 updateConfig(config) {
18 // oxlint-disable-next-line t3code/no-global-process-runtime -- pnpm loads this file before any Effect runtime exists.
19 if (process.platform !== "win32") return config;
20 return {
21 ...config,
22 supportedArchitectures: {
23 os: ["current", "linux"],
24 cpu: ["current", "x64"],
25 libc: ["current", "glibc"],
26 },
27 };
28 },
29 },
30};