labeler
labeler copied to clipboard
Avoid creating labels when the labeler matches patterns in the config file
The labeler
action creates the corresponding labels in GitHub
if not already created when matches are found. Although this might mean less work is needed to create labels, it also means that a PR might create arbitrary labels if the configuration file is modified in that PR. Some organizations may prefer to avoid this and to have a single way to create labels or more control over them. Also, because that somehow breaks the permission criterion that is required to create a new label on a GitHub
repository.
Maybe an option could be added to the configuration of the action preventing it from creating a label if it does not exist in GitHub
.
Following https://github.com/srvaroa/labeler/issues/13#issuecomment-826156061.
Closing as this was solved by @jhlegarreta
Thanks @srvaroa. Not sure if the actions creating labels that are not already available is always desired. I did not address that, but I understand that you might not have time to devote to it.
Oh sorry, I remember we created this AFTER an unrelated change. Reopening :) Thanks for the ping.