yymaxapi 1.0.20 → 1.0.21

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/bin/yymaxapi.js +9 -0
  2. package/package.json +1 -1
package/bin/yymaxapi.js CHANGED
@@ -664,6 +664,15 @@ function detectGatewayEnv(port = 18789) {
664
664
  }
665
665
  }
666
666
  } catch {}
667
+ // Fallback: Windows 没有原生 OpenClaw CLI,但 WSL 里有 → 判定为 WSL
668
+ const nativeCli = resolveCliBinary();
669
+ if (!nativeCli) {
670
+ const wslCli = getWslCliBinary();
671
+ if (wslCli) {
672
+ _gwEnvCache = 'wsl';
673
+ return 'wsl';
674
+ }
675
+ }
667
676
  _gwEnvCache = 'native';
668
677
  return 'native';
669
678
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "yymaxapi",
3
- "version": "1.0.20",
3
+ "version": "1.0.21",
4
4
  "description": "跨平台 OpenClaw/Clawdbot 配置管理工具 - 管理中转地址、模型切换、API Keys、测速优化",
5
5
  "main": "bin/yymaxapi.js",
6
6
  "bin": {