@puku/puku-cli 1.8.31 → 1.8.33

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/puku-cli CHANGED
@@ -29,7 +29,7 @@ function hasNodeOptionFlag(flag) {
29
29
  }
30
30
 
31
31
  function getHeapSizeMb() {
32
- // --max-memory=N flag overrides env var
32
+
33
33
  const maxMemArg = process.argv.find(a => a.startsWith('--max-memory='))
34
34
  if (maxMemArg) {
35
35
  const mb = Number.parseInt(maxMemArg.split('=')[1] || '0', 10)
@@ -58,14 +58,14 @@ function relaunchWithLongSessionHeapIfNeeded() {
58
58
  execArgv.push(`--max-old-space-size=${getHeapSizeMb()}`)
59
59
  }
60
60
 
61
- // --expose-gc enables global.gc() for periodic forced GC in long sessions.
62
- // NODE_OPTIONS cannot carry --expose-gc, so the launcher must inject it here.
61
+
62
+
63
63
  if (!hasExplicitGc) {
64
64
  execArgv.push('--expose-gc')
65
65
  }
66
66
 
67
- // Strip --max-memory before forwarding — it's a launcher-only arg that
68
- // Commander in the built CLI would reject as unknown.
67
+
68
+
69
69
  const childArgs = process.argv
70
70
  .slice(2)
71
71
  .filter(arg => !arg.startsWith('--max-memory=') && arg !== '--max-memory')