forked from wordpress-mobile/WordPress-iOS
-
Notifications
You must be signed in to change notification settings - Fork 1
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
Check labels PR using Danger JS via GitHub action #4
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
We'll use this to eventually run Danger. At the moment, we just want to make sure the workflow runs on the given hooks.
First step to implement wordpress-mobile#13366. The idea is to start with something simple, that is commenting on issues that don't have a label, replicating this Peril config: https://github.com/mokagio/peril-settings/blob/7a7d11f69351d446b8e3a50d9e14a7fdf43a21e4/peril-settings.json#L17-L19. With this into the main branch of the repo, opening, labeling, and un-labeling an issue should result in a workflow run.
I like the standalone setup. This way, we wouldn't need to manage yarn or even add rules to WordPress mobile repo. I do wonder though if it'd be possible to version the file to run, so that we only upgrade it intentionally. In other words, I'd like to avoid a change in the rule made for the sake of one repo breaking the behavior on other repos. 🤔... I guess this is a tradeoff to explore, is centralized management worth the risk?
Weird... The build said it would have removed existing messages, but the warning is still here: |
The main reason for this dedicated commit is to trigger a new build in CI and see if Danger removes the warning regarding not having any labels.
Same as before 😞 . Build passed but warning still in the PR. |
This reverts commit 0bb337a.
😞 , yet another message not removed, despite the build saying so At this point, I wonder if there's a setting I'm missing somewhere. |
That's why we were seeing multiple comments. See: - danger/danger-js#856 (comment) - https://help.github.com/en/actions/configuring-and-managing-workflows/authenticating-with-the-github_token
mokagio
added
enhancement
New feature or request
and removed
enhancement
New feature or request
labels
Feb 11, 2020
Closing in favor of #6. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
As described in #1, since I can't get fast feedback on how Danger interacts with GitHub issues, I'm moving to attempt to integrate Danger in the PR process.
This is all aimed at addressing wordpress-mobile#13366.
Here, we add a GitHub action that runs the shared Peril setting to leave warnings on PRs without labels.
To test this, I'll be adding and removing labels to PRs. If everything works, Danger will post warnings in those PRs via a bot account.
It works on my machine: