@triflux/remote 10.75.0 → 10.76.1

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.
@@ -122,9 +122,21 @@ function parseProbeLines(text) {
122
122
  function normalizePwshProbeEnv(parsed) {
123
123
  if (parsed.shell !== "pwsh" || parsed.os !== "win32") return null;
124
124
  if (!parsed.home) return null;
125
+ const psmuxVersion = parsed.psmuxVersion || null;
126
+ const version = psmuxVersion && parseVersion(psmuxVersion);
125
127
  return Object.freeze({
126
128
  claudePath:
127
129
  !parsed.claude || parsed.claude === "notfound" ? null : parsed.claude,
130
+ psmuxPath:
131
+ !parsed.psmux || parsed.psmux === "notfound" ? null : parsed.psmux,
132
+ psmuxVersion,
133
+ // tfx-psmux.md 규칙 5의 3.3.x detach 미지원 범위를 제외한다. 3.4.0은 일반 이름도 정확 매칭한다.
134
+ psmuxSupported: Boolean(
135
+ parsed.psmux &&
136
+ parsed.psmux !== "notfound" &&
137
+ version &&
138
+ compareVersions(version, [3, 4, 0]) >= 0,
139
+ ),
128
140
  home: parsed.home,
129
141
  os: "win32",
130
142
  shell: "pwsh",
@@ -241,12 +253,13 @@ function probeRemoteEnvViaPwsh(host, execSsh) {
241
253
  "Write-Output 'shell=pwsh'",
242
254
  'Write-Output "home=$env:USERPROFILE"',
243
255
  'if (Test-Path "$env:USERPROFILE\\.local\\bin\\claude.exe") { Write-Output "claude=$env:USERPROFILE\\.local\\bin\\claude.exe" } elseif (Get-Command claude -ErrorAction SilentlyContinue) { Write-Output "claude=$((Get-Command claude).Source)" } else { Write-Output \'claude=notfound\' }',
256
+ 'if (Get-Command psmux -ErrorAction SilentlyContinue) { Write-Output "psmux=$((Get-Command psmux).Source)"; $psmuxVersion = psmux -V 2>$null; if ($LASTEXITCODE -eq 0) { Write-Output "psmuxVersion=$psmuxVersion" } } else { Write-Output \'psmux=notfound\' }',
244
257
  "Write-Output \"os=$([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform([System.Runtime.InteropServices.OSPlatform]::Windows) ? 'win32' : 'other')\"",
245
258
  ].join("; ");
246
259
 
247
260
  try {
248
261
  const output = execSsh(
249
- [...buildSshOptions(), host, "pwsh", "-NoProfile", "-Command", command],
262
+ [...buildSshOptions(), host, pwshRemoteCommand(command)],
250
263
  {
251
264
  encoding: "utf8",
252
265
  timeout: 15000,
@@ -383,8 +396,9 @@ export function probeRemoteEnv(host, opts = {}) {
383
396
  (!opts.osHint ||
384
397
  cached.env.os === opts.osHint ||
385
398
  (opts.osHint === "windows" && cached.env.os === "win32")) &&
386
- (cached.env.os === "win32" ||
387
- ("tmuxPath" in cached.env && "versions" in cached.env))
399
+ (cached.env.os === "win32"
400
+ ? "psmuxVersion" in cached.env && "psmuxSupported" in cached.env
401
+ : "tmuxPath" in cached.env && "versions" in cached.env)
388
402
  )
389
403
  return cached.env;
390
404
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@triflux/remote",
3
- "version": "10.75.0",
3
+ "version": "10.76.1",
4
4
  "description": "triflux remote — team mode, psmux, MCP workers.",
5
5
  "type": "module",
6
6
  "main": "hub/index.mjs",