-
-
Notifications
You must be signed in to change notification settings - Fork 374
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
fix: skip deployment on forks #156
Conversation
Close #153
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've checked the code and while it looks good to me, I thought that it may be better if instead of reporting that the action was successful, as it does right now, it reported the action as skipped, like in the following screenshot:
I've investigated ways to achieve that and it seems that currently the only way to do it is by setting an if
condition that evaluates to false. In a previous version of github actions it was possible to achieve that result by returning the number 78^[1], but that was removed^[2] in a later version, an as of right now and action can only report success or failure^[3]. Github staff have said that they are working on an alternative^[2], but I haven't been able to find any info on that and I believe that hasn't been implemented.
All in all, I believe that is not something currently achievable and the current implementation is good, just wanted to document my investigation to prevent other people wasting time on this.
[1] https://github.saobby.my.eu.orgmunity/t5/GitHub-Actions/GitHub-Actions-quot-neutral-quot-exit-code-is-incorrectly/td-p/29051
[2] https://twitter.com/ethomson/status/1163899559279497217
[3] https://help.github.com/en/actions/reference/development-tools-for-github-actions#setting-an-actions-status-using-exit-codes
Thank you for investigating the neutral exit code. I also know that we could set neutral status by action side in GitHub Actions beta v1. Unfortunately, we have no way to set neutral from GitHub Actions was beta v2. This is one of the most expected features for all GitHub Actions users. I hope this feature will be implemented. |
Codecov Report
@@ Coverage Diff @@
## master #156 +/- ##
==========================================
+ Coverage 51.86% 53.03% +1.16%
==========================================
Files 4 4
Lines 241 247 +6
Branches 40 42 +2
==========================================
+ Hits 125 131 +6
Misses 116 116
Continue to review full report at Codecov.
|
Fixes #153