Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upLimit merge methods to merge button settings #1190
Comments
|
Switching to bug since we ought to be respecting that setting. |
|
I'm guessing we should be querying something like this: {
repository(owner:"cli",name:"cli") {
mergeCommitAllowed
squashMergeAllowed
rebaseMergeAllowed
}
}and adjusting the available options accordingly in Lines 226 to 234 in 02f4946 |
|
New contributor here |
|
Is it possible for a repo to have none of the 3 options enabled? The test for interactive merge fails because the "blueberries" repo we create to test on has none of the options enabled. Just wondering if this can also be a real world case so I can modify the tests accordingly. EDIT: I have created the draft PR and mentioned my problem with the tests. Please take a look and advise on how to fix the test. |


Describe the feature or problem you’d like to solve
The settings for a project allow the merge methods associated with the Merge button to be limited to a subset of the three options
When merging through
gh pr merge, you are presented with a list of all three options regardless.Proposed solution
It would be nice if the options were limited to only the ones supported by the project. To take it one step further, if only one of the options is supported, the question should be skipped entirely.