import type { WorkspaceConfig } from './config-types.js'; /** * Workspace state (registered workspaces + current-workspace pointer) * lives in `~/.peaks/workspaces.json` — NOT in the slim * `~/.peaks/config.json`. The slim config only carries `version` + * `ocr.llm.*`; the user's workspace bookmarks live here. * * This module is the only owner of workspaces.json. Back-compat reads * from `~/.peaks/config.json.workspaces` / `.currentWorkspace` are * tolerated for legacy configs (1.x); the next write promotes the * state into `~/.peaks/workspaces.json` and the legacy config.json * fields are stripped by `loadGlobalConfig` governance. */ type WorkspacesSidecar = { version: string; workspaces: WorkspaceConfig[]; currentWorkspace: string | null; }; export declare function getWorkspaces(): WorkspaceConfig[]; export declare function getCurrentWorkspace(): string | null; export declare function setCurrentWorkspace(workspaceId: string | null): boolean; export declare function addWorkspace(workspace: WorkspaceConfig): void; export declare function removeWorkspace(workspaceId: string): boolean; export declare function getWorkspaceConfig(workspaceId: string): WorkspaceConfig | null; export declare function getCurrentWorkspaceConfig(): WorkspaceConfig | null; export declare function getWorkspaceConfigForPath(path: string): WorkspaceConfig | null; export declare function getWorkspaceConfigForCurrentPath(): WorkspaceConfig | null; export declare function ensureWorkspaceConfigForPath(path: string): WorkspaceConfig | null; export declare function ensureWorkspaceConfigForCurrentPath(): WorkspaceConfig | null; export type { WorkspacesSidecar };