@rickgetz/codex 0.154.0-rick.2 → 0.154.0-rick.20
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.
- package/bin/codex.js +15 -1
- package/package.json +2 -2
package/bin/codex.js
CHANGED
|
@@ -238,11 +238,25 @@ const packageManagerEnvVar =
|
|
|
238
238
|
? "CODEX_MANAGED_BY_PNPM"
|
|
239
239
|
: packageManager === "vite-plus"
|
|
240
240
|
? "CODEX_MANAGED_BY_VITE_PLUS"
|
|
241
|
-
|
|
241
|
+
: "CODEX_MANAGED_BY_NPM";
|
|
242
|
+
// The native child cannot recover the stable npm shim from its own argv[0] or current_exe after
|
|
243
|
+
// an upgrade. Preserve the path that launched this wrapper so an embedded TUI reload can invoke
|
|
244
|
+
// the package resolver again and pick up the replacement vendor binary. Windows uses a Node
|
|
245
|
+
// script entrypoint that cannot be spawned directly by Rust, so its managed-package marker makes
|
|
246
|
+
// Rust reject its versioned vendor argv[0] and report the unsupported-launcher diagnostic.
|
|
247
|
+
const frontendLauncher =
|
|
248
|
+
process.platform === "win32"
|
|
249
|
+
? null
|
|
250
|
+
: path.isAbsolute(process.argv[1] || "")
|
|
251
|
+
? path.resolve(process.argv[1])
|
|
252
|
+
: path.join(codexPackageRoot, "bin", "codex.js");
|
|
242
253
|
const env = {
|
|
243
254
|
...process.env,
|
|
244
255
|
CODEX_MANAGED_PACKAGE_ROOT: codexPackageRoot,
|
|
245
256
|
};
|
|
257
|
+
if (frontendLauncher && !env.CODEX_TUI_FRONTEND_LAUNCHER) {
|
|
258
|
+
env.CODEX_TUI_FRONTEND_LAUNCHER = frontendLauncher;
|
|
259
|
+
}
|
|
246
260
|
delete env.CODEX_MANAGED_BY_NPM;
|
|
247
261
|
delete env.CODEX_MANAGED_BY_BUN;
|
|
248
262
|
delete env.CODEX_MANAGED_BY_PNPM;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rickgetz/codex",
|
|
3
|
-
"version": "0.154.0-rick.
|
|
3
|
+
"version": "0.154.0-rick.20",
|
|
4
4
|
"description": "Codex CLI is a coding agent from OpenAI that runs locally on your computer.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"bin": {
|
|
@@ -20,6 +20,6 @@
|
|
|
20
20
|
},
|
|
21
21
|
"packageManager": "pnpm@10.34.5+sha512.a4ee05f2f73658255bd6a89859c065a45c28a57daefae2c893a168ee2b73168c37b91e83e57ea67654ad03f03031746430e8bce38e362e042605fb8abc80192e",
|
|
22
22
|
"optionalDependencies": {
|
|
23
|
-
"@rickgetz/codex-darwin-arm64": "npm:@rickgetz/codex@0.154.0-rick.
|
|
23
|
+
"@rickgetz/codex-darwin-arm64": "npm:@rickgetz/codex@0.154.0-rick.20-darwin-arm64"
|
|
24
24
|
}
|
|
25
25
|
}
|