A question about --queryformat

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,
I am having a little problem understanding the --queryformat option to rpm.
What I am trying to do is modify the output to the rpm -qf command so that
if I do rpm -qf /etc/auto.* the output shows the filename I am querying.
If I do rpm --querytags one of the options it returns is "filename" so I 
thought doing rpm -qf --qf '%{name} %{filename}\n' /etc/auto.* would return
a list if the pkgnames followed by the filenames that were being tested.
Obviously I was wrong. What I get is this:

(icarus pts12) # rpm -qf --qf '%{name} %{filenames}\n' /etc/auto.*
file /etc/auto.icarus is not owned by any package
autofs /etc/auto.master
autofs /etc/auto.master
file /etc/auto.tigger is not owned by any package
(icarus pts12) #

If I do:
(icarus pts12) # rpm -qf --qf '%{name} %{filenames}\n' /etc/auto.misc
autofs /etc/auto.master
(icarus pts12) # rpm -qf --qf '%{name} %{filenames}\n' /etc/auto.master
autofs /etc/auto.master
(icarus pts12) #

They both return /etc/auto.master for the filename. Is there a way to have
rpm display the filename I am querying in the output?? Can someone tell
me what the filename querytag is really displaying??

TIA,

..............Tom


_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/rpm-list

[Index of Archives]     [RPM Ecosystem]     [Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]

  Powered by Linux