diff options
Diffstat (limited to 'src/main/ipc/handlers.ts')
| -rw-r--r-- | src/main/ipc/handlers.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main/ipc/handlers.ts b/src/main/ipc/handlers.ts index 4894e1d..975ad01 100644 --- a/src/main/ipc/handlers.ts +++ b/src/main/ipc/handlers.ts | |||
| @@ -5,7 +5,7 @@ import * as claude from "../claude"; | |||
| 5 | import * as settingsDb from "../db/settings"; | 5 | import * as settingsDb from "../db/settings"; |
| 6 | import { createSessionBranch, ensureGitIgnore, ensureGitRepo, getCurrentBranch } from "../git"; | 6 | import { createSessionBranch, ensureGitIgnore, ensureGitRepo, getCurrentBranch } from "../git"; |
| 7 | import { discoverMcpTools } from "../mcp"; | 7 | import { discoverMcpTools } from "../mcp"; |
| 8 | import type { UserPermissionMode } from "../claude/phases"; | 8 | import type { UserPermissionMode, Phase } from "../claude/phases"; |
| 9 | import { getDefaultSystemPromptTemplate } from "../claude/phases"; | 9 | import { getDefaultSystemPromptTemplate } from "../claude/phases"; |
| 10 | 10 | ||
| 11 | export function registerIpcHandlers(mainWindow: BrowserWindow): void { | 11 | export function registerIpcHandlers(mainWindow: BrowserWindow): void { |
| @@ -23,11 +23,11 @@ export function registerIpcHandlers(mainWindow: BrowserWindow): void { | |||
| 23 | sessions.listSessions(projectId) | 23 | sessions.listSessions(projectId) |
| 24 | ); | 24 | ); |
| 25 | 25 | ||
| 26 | ipcMain.handle("sessions:create", (_, projectId: string, name: string) => { | 26 | ipcMain.handle("sessions:create", (_, projectId: string, name: string, phase?: Phase) => { |
| 27 | const project = projects.getProject(projectId); | 27 | const project = projects.getProject(projectId); |
| 28 | if (!project) throw new Error("Project not found"); | 28 | if (!project) throw new Error("Project not found"); |
| 29 | 29 | ||
| 30 | const session = sessions.createSession(projectId, name); | 30 | const session = sessions.createSession(projectId, name, phase); |
| 31 | 31 | ||
| 32 | // Ensure .claude-flow/ is gitignored from day one. | 32 | // Ensure .claude-flow/ is gitignored from day one. |
| 33 | // Branch creation is deferred until the session advances to implement. | 33 | // Branch creation is deferred until the session advances to implement. |
