Not planned
Description
From go-gitea/gitea#25667 (comment), I think it would be useful if the bot could auto-set some labels based on modified path. There are two kind of matching mechanisms needed:
- If any path is modified. For example, every change in
Makefile
should get abuild
label. - If only a path is modified. For example a change only in
docs
should get akind/docs
label and maybe askip-changelog
, but a change that includes changes indocs
andtemplates
should not.
The config should be in the repo itself in .github/giteabot.yaml
to be flexible to change:
autolabels:
only:
- globs: [docs/**]
labels: [kind/docs, skip-changelog]
any:
- globs: [Makefile]
labels: [build]
Activity
yardenshoham commentedon Jul 4, 2023
I think it makes more sense to have the file here
silverwind commentedon Jul 4, 2023
Multiple benefits of having bot config in-repo:
silverwind commentedon Sep 1, 2023
Something like this would be nice:
https://github.com/nodejs/node/blob/main/.github/label-pr-config.yml
Regex (with capture groups!) is the absolute flexibilty.
silverwind commentedon Sep 1, 2023
BTW, Here is the repo for that bot which is acually just a action in disguise:
https://github.com/nodejs/node-pr-labeler
silverwind commentedon Sep 1, 2023
Of course more generic actions for this exist, like https://github.com/actions/labeler, so I think we likely should not do it in this bot at all.
yardenshoham commentedon Sep 1, 2023
Agreed
actions/labeler
go-gitea/gitea#26962Add `actions/labeler` (#26962)