PRM outputs in XML

38 views
asked May 7, 2012 in General by megatester (180 points)
Hi
On the main page of rpm, it’s mentioned that it supports option '--xml' to the query format switch that will wrap the results in simple XML. I am not able to find the right syntax.
How do I get the output of an rpm call in XML via the '--xml' option? What is the syntax?
Please help
Thanks,

1 Answer

0 like 0 dislike
answered May 7, 2012 by lightSpeed (2,420 points)
This is the syntax that you're looking for

rpm -q --xml --qf '%{name}\n' httpd
...