Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions cmd/finish.go
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,14 @@ func executeFinish(branchType string, name string, continueOp bool, abortOp bool
shortName = parts[len(parts)-1]
}

// If a different parent branch was used to create the branch, use this instead of the configured one
if startPoint, err := git.GetBaseBranch(name); err == nil {
if startPoint != branchConfig.StartPoint {
fmt.Printf("Using base branch '%s'\n", startPoint)
branchConfig.Parent = startPoint
}
}

// Resolve all options once before starting operations
resolvedOptions := config.ResolveFinishOptions(cfg, branchType, shortName, tagOptions, retentionOptions, mergeOptions, fetch, noVerify)

Expand Down