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

update changelog and website checks #9781

Merged
merged 2 commits into from
Feb 26, 2021
Merged

Conversation

alvin-huang
Copy link
Collaborator

@alvin-huang alvin-huang commented Feb 17, 2021

This PR splits out the website/ check to only run on PR opened while the changelog check runs on opened, synchronize (new commits) and labeled and also changes it to a status check that fails when there is no pr/no-changelog label applied nor is there a .changelog/$pr_number.txt file.

I also changed the on trigger to be pull_request for the changelog check because it no longer needs a token secret to post to the PR so it doesn't need to only run on pull_request_target

@alvin-huang alvin-huang requested a review from dnephin February 17, 2021 22:31
@github-actions github-actions bot added the theme/contributing Additions and enhancements to community contributing materials label Feb 17, 2021
@hashicorp-ci
Copy link
Contributor

🤔 Double check that this PR does not require a changelog entry in the .changelog directory. Reference

@alvin-huang
Copy link
Collaborator Author

🤔 Double check that this PR does not require a changelog entry in the .changelog directory. Reference

This will go away after this gets merged, it's running the old check in the master branch.

@alvin-huang alvin-huang added the pr/no-changelog PR does not need a corresponding .changelog entry label Feb 17, 2021
@dnephin dnephin added pr/no-changelog PR does not need a corresponding .changelog entry and removed pr/no-changelog PR does not need a corresponding .changelog entry labels Feb 19, 2021
Copy link
Contributor

@dnephin dnephin left a comment

Choose a reason for hiding this comment

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

LGTM!

One question, but not blocking, probably just a minor optimization.

Comment on lines +21 to +23
with:
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 0 # by default the checkout action doesn't checkout all branches
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we omit this now that it uses on: pull_request instead of target?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I can test but I don't think so, we still need to checkout all branches to compare the HEAD to the base ref (which wouldn't be checked out if we just checkout HEAD).

@alvin-huang alvin-huang merged commit efd68a8 into master Feb 26, 2021
@alvin-huang alvin-huang deleted the ci/fix-github-action-logic branch February 26, 2021 21:29
@hashicorp-ci
Copy link
Contributor

🍒 If backport labels were added before merging, cherry-picking will start automatically.

To retroactively trigger a backport after merging, add backport labels and re-run https://circleci.com/gh/hashicorp/consul/333004.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr/no-changelog PR does not need a corresponding .changelog entry theme/contributing Additions and enhancements to community contributing materials
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants