mirror of
https://github.com/AutoMaker-Org/automaker.git
synced 2026-02-01 20:23:36 +00:00
fix: merge worktree handler now uses correct branch name and path
The merge handler previously hardcoded branch names as `feature/${featureId}`
and worktree paths as `.worktrees/${featureId}`, which failed for auto-generated
branches (e.g., `feature/v0.11.0rc-1768413895104-31pa`) and custom worktrees.
Changes:
- Server handler now accepts branchName and worktreePath directly from the UI
- Added branch existence validation before attempting merge
- Updated merge dialog with 2-step confirmation (type "merge" to confirm)
- Removed feature branch naming restriction - any branch can now be merged
- Updated API types and client to pass correct parameters
Closes #408
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -1706,8 +1706,12 @@ export class HttpApiClient implements ElectronAPI {
|
||||
|
||||
// Worktree API
|
||||
worktree: WorktreeAPI = {
|
||||
mergeFeature: (projectPath: string, featureId: string, options?: object) =>
|
||||
this.post('/api/worktree/merge', { projectPath, featureId, options }),
|
||||
mergeFeature: (
|
||||
projectPath: string,
|
||||
branchName: string,
|
||||
worktreePath: string,
|
||||
options?: object
|
||||
) => this.post('/api/worktree/merge', { projectPath, branchName, worktreePath, options }),
|
||||
getInfo: (projectPath: string, featureId: string) =>
|
||||
this.post('/api/worktree/info', { projectPath, featureId }),
|
||||
getStatus: (projectPath: string, featureId: string) =>
|
||||
|
||||
Reference in New Issue
Block a user