spudmobile-bridge 1.0.4 → 1.0.5

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.
Files changed (2) hide show
  1. package/dist/codex.js +3 -3
  2. package/package.json +1 -1
package/dist/codex.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { spawn, execSync } from 'child_process';
2
+ import { realpathSync } from 'fs';
2
3
  /**
3
4
  * Find the Codex CLI binary path
4
5
  */
@@ -7,7 +8,7 @@ export function findCodexCLI() {
7
8
  try {
8
9
  const result = execSync('which codex', { encoding: 'utf-8' }).trim();
9
10
  if (result)
10
- return result;
11
+ return realpathSync(result);
11
12
  }
12
13
  catch {
13
14
  // not in PATH
@@ -58,11 +59,10 @@ export function runCodex(prompt, cliPath, options = {}, onChunk) {
58
59
  args.push('--full-auto');
59
60
  args.push('--skip-git-repo-check');
60
61
  const timeout = options.timeout || 10 * 60 * 1000; // 10 min default
61
- const proc = spawn(cliPath, args, {
62
+ const proc = spawn(process.execPath, [cliPath, ...args], {
62
63
  cwd: options.cwd || process.cwd(),
63
64
  env: { ...process.env },
64
65
  stdio: ['pipe', 'pipe', 'pipe'],
65
- shell: true,
66
66
  });
67
67
  // Close stdin immediately — exec mode doesn't need it
68
68
  if (proc.stdin) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "spudmobile-bridge",
3
- "version": "1.0.4",
3
+ "version": "1.0.5",
4
4
  "description": "Bridge between OpenAI Codex CLI and SpudMobile iOS app via Supabase",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",