Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
We were hitting an error where gh pr create would fail when a PR already existed for a branch. This is unfortunately not an easy case to handle, as the tool isn't very smart. See: cli/cli#5792 To work-around that limitation, we first try to edit the PR. If that fails, we create a new PR. However, I've noticed edit will succeed for closed PRs (which makes sense), so we try to reopen after edit, which succeeds if the PR is already open. This is not working 100% as intended, as gh pr reopen currently fails to actually reopen closed PRs. The end result is reasonable, though, as we get a newly created PR when the previous one was closed.
- Loading branch information