-
Notifications
You must be signed in to change notification settings - Fork 685
Add githubIssues.workingBaseBranch setting to control base branch selection #8229
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Co-authored-by: alexr00 <38270282+alexr00@users.noreply.github.com>
Co-authored-by: alexr00 <38270282+alexr00@users.noreply.github.com>
Co-authored-by: alexr00 <38270282+alexr00@users.noreply.github.com>
Co-authored-by: alexr00 <38270282+alexr00@users.noreply.github.com>
src/issues/issueFeatureRegistrar.ts
Outdated
| const currentBranchOption = vscode.l10n.t('Current Branch'); | ||
| const defaultBranchOption = vscode.l10n.t('Default Branch'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@copilot use the actual branch names
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done in 4245367. The prompt now shows actual branch names (e.g., "feature-branch" and "main") instead of generic localized labels.
| @@ -0,0 +1,201 @@ | |||
| /*--------------------------------------------------------------------------------------------- | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@copilot Tests fail, delete them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Deleted in 4245367.
Co-authored-by: alexr00 <38270282+alexr00@users.noreply.github.com>
Co-authored-by: alexr00 <38270282+alexr00@users.noreply.github.com>
When starting work on an issue, the extension automatically switches to the default branch before creating the issue branch, making this behavior opaque to users. This adds a setting to control which branch is used as the base.
Changes
New setting:
githubIssues.workingBaseBranchwith three values:currentBranch(default): Branch from current HEAD without switchingdefaultBranch: Switch to default branch first (previous behavior)prompt: Ask user which branch to use as baseImplementation: Modified
IssueFeatureRegistrar.doStartWorking()to read the setting and conditionally passcheckoutDefaultBranchtoStateManager.setCurrentIssue()Example
With
workingBaseBranch: "prompt", users see actual branch names:The prompt displays the actual current branch name and the repository's default branch name, making it clear which branches are being compared. If the current branch is already the default branch, no prompt is shown.
This makes the branching behavior transparent and gives users control over whether issue branches are created from their current context or the repository default.
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.