@alexkroman1/aai-cli 1.9.2 → 1.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,31 +0,0 @@
1
- #!/usr/bin/env node
2
- //#region _vite-env.ts
3
- /**
4
- * Run a Vite build without letting it mutate the calling process's env.
5
- *
6
- * Vite's `build()` sets `process.env.NODE_ENV = "production"` when NODE_ENV is
7
- * unset — a global, permanent side effect on whatever process invoked it. That
8
- * is fine for a one-shot `aai build`, but both long-lived callers are broken by
9
- * it:
10
- *
11
- * - `aai dev` rebuilds on every file change, so the first rebuild would flip
12
- * the dev server into production mode.
13
- * - The platform studio builds inside the server process, where flipping
14
- * NODE_ENV makes the sandbox demand gVisor ("gVisor (runsc) is required in
15
- * production but not found on PATH") and refuse every subsequent deploy on a
16
- * dev machine.
17
- *
18
- * Snapshot and restore rather than pinning a value: callers that legitimately
19
- * run with NODE_ENV=production must keep it.
20
- */
21
- async function withPreservedNodeEnv(fn) {
22
- const saved = process.env.NODE_ENV;
23
- try {
24
- return await fn();
25
- } finally {
26
- if (saved === void 0) delete process.env.NODE_ENV;
27
- else process.env.NODE_ENV = saved;
28
- }
29
- }
30
- //#endregion
31
- export { withPreservedNodeEnv as t };
package/dist/types.mjs DELETED
@@ -1,2 +0,0 @@
1
- #!/usr/bin/env node
2
- export {};