On Mon, Nov 22, 2021 at 9:55 PM Matthew Miller <mattdm(a)fedoraproject.org> wrote:
rpm -qa --qf '%{sourcerpm}\n'
gives me a list of source RPM names, but it's in filename format. I don't
want to have to try to parse that to figure out the actual source package
base name (i.e. the dist-git name). Is there something I'm missing? Probably
there is. :)
When in doubt, dnf's repoquery is usually more powerful than rpmquery
(even if its arguments are somewhat opaque at times):
$ dnf repoquery --installed --qf "%{source_name}"
Gives you the list of source package names for all installed packages.
Fabio