Skip to content
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

feat: implement gh pr revert #8826

Open
wants to merge 3 commits into
base: trunk
Choose a base branch
from

Conversation

lucasmelin
Copy link

Fixes #6034

Adds a new pr revert command that enables reverting a merged PR using the gh CLI.

Usage

# Revert a PR
$ gh pr revert 123

# Provide revert PR options
$ gh pr revert --draft --title 'Example title' --body 'Example body' 123

@lucasmelin lucasmelin requested a review from a team as a code owner March 17, 2024 03:43
@lucasmelin lucasmelin requested review from williammartin and removed request for a team March 17, 2024 03:43
@cliAutomation cliAutomation added the external pull request originating outside of the CLI core team label Mar 17, 2024
@cliAutomation cliAutomation added this to Needs review 🤔 in The GitHub CLI Mar 17, 2024
@lucasmelin
Copy link
Author

Putting back into draft to add the revert PR details to the success message output.

@lucasmelin lucasmelin marked this pull request as draft March 17, 2024 13:06
@lucasmelin
Copy link
Author

Added the revert PR details to the message output, ready for review.

@lucasmelin lucasmelin marked this pull request as ready for review March 17, 2024 13:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
external pull request originating outside of the CLI core team
Projects
No open projects
The GitHub CLI
  
Needs review 🤔
Development

Successfully merging this pull request may close these issues.

Provide gh cli Support to Revert Pull Request
2 participants