Comments (3)
Thanks for reporting!
I think there is indeed a bug in the condition evaluations that will indeed take only the result of the latest condition, I'll review it later and try to get it fixed.
That said I'm not sure fixing this will give you the result you expect. I understand from your report that you'd actually want an OR (e.g. apply the label if either the title or files match). Is that right?
The current (buggy) implementation tries to AND
all conditions, so this:
WIP:
title: "^WIP:.*"
files:
- "cmd/.*_tests.go"
Would only apply the label if both conditions match.
It's possible to implement the OR behaviour with minor changes. If you're interested in that I can get both changes in.
from labeler.
Yeah, Ideally it would apply if any of the conditions are met. I guess a workaround for this could be listing the label twice.
from labeler.
Hi @Stoom this PR should fix both the bug, and allow implementing the OR with multiple matchers (it requires an update in config format but it should be fairly straight forward).
I've added a few tests for this so I'm fairly confident this will work, but if you can give it a go using that branch (with this in your github workflows yaml):
- uses: srvaroa/[email protected]
That'd be very appreciated.
from labeler.
Related Issues (20)
- `appendOnly: true` doesn't seem to work HOT 4
- ~~What flavour of regex is being used ?~~ README: add info about using escape character in regexes HOT 3
- `fail_on_error: true` doesn't seem to work HOT 4
- Could a "moving" `v1` tag be added to this repo ? HOT 2
- 1.8.0 release failed HOT 2
- Enhanced label customization HOT 2
- author-can-merge: false does not seem to work HOT 13
- Negative lookahead is not supported HOT 6
- Some regex not working in filter via property HOT 4
- Build fails due to missing imports `gopkg.in/check.v1` & `gopkg.in/yaml.v2` HOT 3
- Docker build failed HOT 4
- Add support for issues HOT 5
- [Feature] Naming labels based on regex capture groups HOT 1
- Ignore files in PR Size condition HOT 3
- Semantic versioning HOT 5
- [Feature] support local config file HOT 2
- Cannot run the action since 1.6.2 release: action.tar.gz not found HOT 4
- [Labeler] job no more working -- Docker build failed with exit code 1 HOT 2
- Avoid referencing `latest` in Dockerfile HOT 2
- label based on name of PR target branch HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from labeler.