(id: string)
| 469 | } |
| 470 | |
| 471 | export async function getGitStatus(id: string): Promise<GitStatus> { |
| 472 | const res = await fetch(`/api/workspaces/${encodeURIComponent(id)}/git/status`); |
| 473 | if (!res.ok) throw new Error(`git status failed: ${res.status}`); |
| 474 | return (await res.json()) as GitStatus; |
| 475 | } |
| 476 | |
| 477 | // ── files ──────────────────────────────────────────────────────────────────── |
| 478 |