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

GitHub Automerge Types #466

Merged
merged 2 commits into from
Feb 11, 2019
Merged

GitHub Automerge Types #466

merged 2 commits into from
Feb 11, 2019

Conversation

lkysow
Copy link
Member

@lkysow lkysow commented Feb 11, 2019

For repos with certain merge methods disabled (such as 'merge'), simply
hitting the GitHub /merge endpoint is not sufficient. Instead, we need
to check which methods are actually available, then use the appropriate
method.

With this change it will:

  1. Default to 'merge' if enabled
  2. Use 'rebase' if 'merge' is disabled and rebase is enabled
  3. Use 'squash' if 'merge' is disabled

Notes:

Brenden Matthews and others added 2 commits February 7, 2019 16:18
For repos with certain merge methods disabled (such as 'merge'), simply
hitting the GitHub `/merge` endpoint is not sufficient. Instead, we need
to check which methods are actually available, then use the appropriate
method.

With this change it will:

 1. Default to 'merge' if enabled
 2. Use 'rebase' if 'merge' is disabled and rebase is enabled
 3. Use 'squash' if 'merge' is disabled
@codecov
Copy link

codecov bot commented Feb 11, 2019

Codecov Report

Merging #466 into master will increase coverage by 0.06%.
The diff coverage is 88.23%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master    #466      +/-   ##
=========================================
+ Coverage   70.53%   70.6%   +0.06%     
=========================================
  Files          63      63              
  Lines        4243    4259      +16     
=========================================
+ Hits         2993    3007      +14     
- Misses       1028    1029       +1     
- Partials      222     223       +1
Impacted Files Coverage Δ
server/events/vcs/github_client.go 73.39% <88.23%> (+2.42%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a08cec9...def41f6. Read the comment docs.

Copy link

@brndnmtthws brndnmtthws left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good 👍

allowSquash bool
expMethod string
}{
"all true": {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

@lkysow lkysow merged commit 45a6823 into master Feb 11, 2019
@lkysow lkysow deleted the gh-automerge branch February 11, 2019 17:22
@lkysow
Copy link
Member Author

lkysow commented Feb 11, 2019

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