Files
goose/ui/desktop/src/sessions.ts
Douwe Osinga dc292883b7 Session manager (#4648)
Co-authored-by: Douwe Osinga <douwe@squareup.com>
2025-09-26 14:56:45 -04:00

17 lines
449 B
TypeScript

import { Session } from './api';
export function resumeSession(session: Session) {
console.log('Launching session in new window:', session.description || session.id);
const workingDir = session.working_dir;
if (!workingDir) {
throw new Error('Cannot resume session: working directory is missing in session');
}
window.electron.createChatWindow(
undefined, // query
workingDir,
undefined, // version
session.id
);
}