Webrev:
https://cr.opensolaris.org/action/browse/pkg/bpytlik/7140060-v2
Bug:
7140060 install and update should allow multiple pattern matches
when they intersect
This change attempts to make users' lives simpler when they're trying to
select specific packages to update or install. One principle I tried to
adhere to was that specifying a more general version of a pattern
wouldn't cause a previously successful command to fail. The hierarchy of
specificity looks like this (from least to most specific):
wildcarded pattern with no publisher set
wildcarded pattern with publisher set
specific package name with or without a publisher set
A more specific pattern overrides a less specific one.
While I think the easiest way to get a handle on how the implemented
behavior plays out is to look at the new tests, I've attempted to
describe in words the policy that's been implemented:
If multiple patterns within the same level match the same package name,
then the intersection of the specific fmris they matched is used to
select the possible packages. If the intersection is empty, then that's
an error. For the patterns with a specific package name, the publishers
that were provided as part of the patterns are also intersected (where
patterns which don't specify a publisher are treated as matching all
known publishers). Since each pattern can specify either 1 or all
publishers, the intersection is either a single publisher or all
publishers. If a single publisher is found, only packages from that
publisher are considered. If all publishers is the result, then
publisher ranking and stickiness is used.
Thanks,
Brock
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss