mheap / github-action-required-labels

Fail the build if/unless a certain combination of labels are applied to a pull request
MIT License
99 stars 23 forks source link

Attempts to add comment when default is "false" #39

Closed garytimuss closed 1 year ago

garytimuss commented 1 year ago

fatal Error: The GITHUB_TOKEN environment variable must be set to add a comment

We don't have GITHUB_TOKEN env set because we don't want to add a comment

exitWithError should give the error instead is failing

description: "Add a comment to the PR if required labels are missing"
default: "false"
required: false

Expect the default should be false not "false" for boolean test to fail by default to not add the comment caused by https://github.com/mheap/github-action-required-labels/commit/4ae53dd40a63ca66263a72d9d88b2747c3b7c4b7#

mheap commented 1 year ago

Thanks for the report! I've just published 2.2.3 that resolves this issue. Sorry for the unintentional break - I'm adding unit tests for this behaviour now