-
Notifications
You must be signed in to change notification settings - Fork 2.4k
feat: Adds a 'Create PR' button to the button bar after attempt_completion #9021
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
- Remove /create-pr built-in slash command from built-in-commands.ts
- Add CREATE_PR Support Prompt type with same functionality
- Update Chat UI button to use supportPrompt.create('CREATE_PR')
- Add CREATE_PR translations to all 17 locales
- Revert unrelated slash command tool changes to original state
- Add comprehensive tests for CREATE_PR prompt
The Create PR button now uses a customizable prompt template editable in Settings > Prompts, while maintaining the same user experience.
…llation confirmation
|
Review complete. Latest commit is a clean Italian translation typo fix. Previous UX issue remains unresolved:
Mention @roomote in a comment to trigger your PR Fixer agent and make changes to this pull request. |
Co-authored-by: ellipsis-dev[bot] <65095814+ellipsis-dev[bot]@users.noreply.github.com>
| // Check if primary button is "Create PR" | ||
| if (primaryButtonText === t("chat:createPR.title")) { | ||
| // Mark that PR creation was requested | ||
| setPrCreationRequested(true) | ||
| // Send message using the Support Prompt for PR creation | ||
| const text = supportPrompt.create("CREATE_PR", {}, customSupportPrompts) | ||
| handleSendMessage(text, []) |
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.
Clicking the "Create PR" button clears any text the user has typed in the input field. This differs from the follow-up suggestion behavior (lines 1514-1521) which preserves user input. Users may have typed additional context or instructions before clicking "Create PR" and will lose that text unexpectedly.
Fix it with Roo Code or mention @roomote and request a fix.
Description
In an effort to help fit within users' workflows, this changes the UI after
attempt_completionto show these buttons, instead of just "Start New Task"Which then goes through a workflow which creates a PR on behalf of the user (if gh cli tools are available) or pushes to the remote branch and shares a link to create the PR.
To do that:
/create-pr)git.tsutil file to be better aware of what's a git repo workspace or not, namely to be aware of worktrees (which is worthwhile on its own – and I'm a heavy worktree user)attempt_completionand, if it is, shows the button.Missing nice-to-have: I'm showing the
Create PRbutton every time it's eligible according to what's described above. But ideally we should only show it if it's a git repo and either there are unstaged changes or there are commits in a non-main/master branch. Checking for that seemed too complex for now, it seems non-blocking but a good improvement.Test Procedure
Create PRbuttonImportant
Adds a 'Create PR' button in the UI for GitHub repositories, with supporting command and localization updates.
ChatView.tsxfor GitHub repositories.attempt_completionif in a GitHub repo./create-prcommand to facilitate PR creation.ClineProviderto check for GitHub repository status.This description was created by
for 44a7786. You can customize this summary. It will automatically update as commits are pushed.