On Tue, Nov 23, 2021 at 09:43:30AM +0100, Petr Pisar wrote:
V Mon, Nov 22, 2021 at 07:32:26PM -0500, Matthew Miller napsal(a):
> But in any case, it doesn't solve my problem, as it just gives filenames,
> and there's no way to know when a name ends and a version starts, as they
> both use - as a separator.
>
The hyphen separator is forbidden inside release and version parts. Thus the
solution is parse the file name from the end. Example:
IIRC this is now only valid for regular RPMs. RPMs build as part of modularity
can have a hyphen in the "stream" part (which is included in the release).
I do not know if we have any actual case, but in theory it is the case.
Pierre