-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 On 09/13/2015 09:35 PM, konsolebox wrote: > Many times we need to match packages like this: something-1.0.2a.* > > But that expression is not allowed with ~ (only targets revisions) > and neither with * (.*) is invalid. > > So my suggestion is to add ~> as another operator. With it we can > have an expression like '~>pkg-1.0.2a' and it would be equivalent > to '>=pkg-1.0.2a' and '<pkg-1.0.2b'. Another expression like > '~>pkg-1.0.2' would be equivalent to '>=pkg-1.0.2' and > '<pkg-1.0.3'. > > If comparing by arithmetic operations turns out to be difficult > (i.e. predicting the next version to compare against), then maybe > we could just compare it with pattern(s). For example if we have > 'pkg-1.02a' as the base version, then the valid versions we need to > get are 'pkg-1.02a', 'pkg-1.02a.*' and > 'pkg-1.02a(_(alpha|beta|pre|p)|-r)[0-9]+'. > > The operator is copied from Ruby's Gemfile so it would be familiar > to anyone developing Ruby as well. > Honestly, this situation looks like a perfect candidate for slotting instead of adding a new feature. If SLOT is setup correctly between ebuilds, you could check to be sure it's a specific SLOT. So in your case, pkg-1.0.2[a-z] would be slotted with e.g. pkg-1.0.2g:1.0.2. Anything depending on it would use `pkg:1.0.2`, and the pkg-1.0.3a ebuild could use SLOT="1.0.3" and be called as a dependency via `pkg:1.0.3`.
Just my two cents. - -- Daniel Campbell - Gentoo Developer OpenPGP Key: 0x1EA055D6 @ hkp://keys.gnupg.net fpr: AE03 9064 AE00 053C 270C 1DE4 6F7A 9091 1EA0 55D6 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJV9l1KAAoJEAEkDpRQOeFwM4gQANPEqNiTHQDU55eH//Iw3KVw W3U2DoPR1YuxALF4vCrxDACcHxtwR0k7L7j54Hkpc6y8V93z9aJIEj396ktNSmk9 BYGzH+M/IO4VsEjm9Ns9GZn4fxQ2YUw3v7SVq+kqmBDNwkKU/5ZsR2XaGykQSuMQ smTuZCCILdx3/6QfKQvvk6tuA6kEzLIuCpXE8l56uXJJzpKb+syWSefZftO31PU4 Qbj8zWlRMNoUEEQpJT7yTEzrfvRvFsMPPiHKUYw05WxjuQZzf52GZSdvBMDTTqGu Ltf4BjSF/4c01zMmh3qMKmIiVzCq4pGLv0IcQ0DJmh8KAzYGP++Y+deAHLztyVGu Fx793wps+/ZdfY86QQ+NFD9QHUT8RLCRvr+87YmNwQqxwQCErBF1KeQfbw0NB4m9 tyegRLXgiVlR9yDIo736vTyxPwHe9xtOtFMsOQRPIfKI3T8KzZlxEsAj7kfoMX16 eKeeJlKB2WU4wQ6tbDm3Gjjk0dZmVrU7ZAnVwG5KbXtz4oPp+rwbyX4fn8uG9rVB XVJfLfJjXtkjFliFeUAKdRcm9ZyuKTO5BIppC7RCajEaHkuXSCRoBu7RpbwkyT+V IMBz0Y6/dZyHMplfp5UGIqPMyUqYKQXh1MREro9xqSisxwf9RpDVj38OrbvjdvRW 7uilEYxSlijwOnWeCvG6 =EtOQ -----END PGP SIGNATURE-----