-
Notifications
You must be signed in to change notification settings - Fork 7.8k
Closed
Labels
bugSomething isn't workingSomething isn't workingneeds-triageneeds to be reviewedneeds to be reviewed
Description
Describe the bug
gh pr create when run non-interactively no longer works, a git bisect shows that it started happening after 2944f7c was merged.
Steps to reproduce the behavior
- Clone a GitHub repository
- Add a fork with
gh repo fork --remote --remote-name=fork - Create empty commit with
git commit -m empty --allow-empty - Push commit to fork with
git push -u fork - Attempt to create a PR (non-interactively)
gh pr create --fill < /dev/null - See error
Expected vs actual behavior
With v2.17.0 (expected behavior)
> gh --version
gh version 2.17.0 (2022-10-04)
https://github.com/cli/cli/releases/tag/v2.17.0
> gh pr create --fill < /dev/null
(successful creation of the PR)
With v2.18.0 (incorrect behavior)
> gh --version
gh version 2.18.0 (2022-10-18)
https://github.com/cli/cli/releases/tag/v2.18.0
> gh pr create --fill < /dev/null
aborted: you must first push the current branch to a remote, or use the --head flag
It looks like the above is caused by commit 2944f7c.
Logs
See above.
ajaykumarkannan and rnorth
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingneeds-triageneeds to be reviewedneeds to be reviewed