fix(tui): resolve screen attach ambiguity with multiple sessions

- Add getFullScreenId() to get PID.screenName format for unambiguous attach
- Update DirectAttach.ts and index.tsx to use full screen IDs
- Remove TUI documentation from README (still in development)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
arkon
2026-01-21 12:52:38 +01:00
co-authored by Claude Opus 4.5
parent e6ba373d12
commit e8c30b9880
11 changed files with 737 additions and 219 deletions
+17
View File
@@ -854,6 +854,23 @@ export class WebServer extends EventEmitter {
}
this.broadcast('session:updated', { session: session.toDetailedState() });
// Save lastUsedCase to settings for TUI/web sync
try {
const settingsFilePath = join(homedir(), '.claudeman', 'settings.json');
let settings: Record<string, unknown> = {};
if (existsSync(settingsFilePath)) {
settings = JSON.parse(readFileSync(settingsFilePath, 'utf-8'));
}
settings.lastUsedCase = caseName;
const dir = dirname(settingsFilePath);
if (!existsSync(dir)) {
mkdirSync(dir, { recursive: true });
}
writeFileSync(settingsFilePath, JSON.stringify(settings, null, 2));
} catch {
// Non-critical, ignore settings save errors
}
return {
success: true,
sessionId: session.id,