-
Notifications
You must be signed in to change notification settings - Fork 991
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
allow regex pattern for conf tools.info.package_id:confs #14621
allow regex pattern for conf tools.info.package_id:confs #14621
Conversation
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.
Thanks for your contribution!
I think this is looking good, but I'd try to generalize it to cover also user.*
confs, I think it is doable.
Also, it is better if you target the release/2.0
branch, as that means it will go into the next 2.0.11
, not need to wait until the 2.1
.
conans/model/conf.py
Outdated
# Pruning any empty values, those should not affect package ID | ||
if value: | ||
result.define(conf_name, value) | ||
matching_confs = [c for c in BUILT_IN_CONFS if re.match(conf_name, c)] or [conf_name] |
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.
A quick question: If we also want to match the user.mycomp.*
confs, then we would need to iterate better the defined values in the current conf, rather than matching against the BUILT_IN_CONFS
? I think this would be a more general approach.
608b6dc
to
c6e276b
Compare
Changelog: Feature: Supporting regex pattern for conf
tools.info.package_id:confs
Docs: conan-io/docs#3382
Ref: #14620
develop
branch, documenting this one.