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

Add GitHub Enterprise compatibility #31

Merged
merged 3 commits into from
Sep 16, 2020
Merged

Conversation

GUI
Copy link
Contributor

@GUI GUI commented Aug 13, 2020

  • Add --base-url argument for pointing at a GitHub Enterprise API URL.
  • Add --enterprise-compatibility flag for loading the @octokit/plugin-enterprise-compatibility plugin which is needed for the API to work against GitHub Enterprise's API before v2.19.
  • Add --skip-update-branch-protection flag for skipping the update branch protection step. While this perhaps isn't ideal, this part of the GraphQL API wasn't supported until GitHub Enterprise API v2.15. If you weren't using protected branches, then this might be okay to skip.
  • When running in verbose made, don't make failures to the rate limit API fatal, since GitHub Enterprise API versions may not support this endpoint.
  • When updating the default_branch via the API, also pass the name parameter, which appears to be required for some older API versions: https://github.saobby.my.eu.orgmunity/t/cannot-change-default-branch/13728/13

GUI and others added 3 commits August 13, 2020 16:10
- Add `--base-url` argument for pointing at a GitHub Enterprise API URL.
- Add `--enterprise-compatibility` flag for loading the
  [`@octokit/plugin-enterprise-compatibility`](https://github.com/octokit/plugin-enterprise-compatibility.js/)
  plugin which is needed for the API to work against GitHub Enterprise's
  API before v2.19.
- Add `--skip-update-branch-protection` flag for skipping the update
  branch protection step. While this perhaps isn't ideal, this part of
  the GraphQL API wasn't supported until GitHub Enterprise API v2.15. If
  you weren't using protected branches, then this might be okay to skip.
- When running in verbose made, don't make failures to the rate limit
  API fatal, since GitHub Enterprise API versions may not support this
  endpoint.
- When updating the `default_branch` via the API, also pass the `name`
  parameter, which appears to be required for some older API versions:
  https://github.saobby.my.eu.orgmunity/t/cannot-change-default-branch/13728/13
* Reformat README using prettier
* Fix Otcokit typo
* Add new --skip-update-branch-protection option
@mheap mheap merged commit ce5f12c into mheap:main Sep 16, 2020
@mheap
Copy link
Owner

mheap commented Sep 16, 2020

This is awesome! Thanks for the contributions @GUI

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants