{"id":247,"date":"2013-04-25T12:54:27","date_gmt":"2013-04-25T17:54:27","guid":{"rendered":"http:\/\/www.popmartian.com\/tipsntricks\/?p=247"},"modified":"2013-04-25T12:54:27","modified_gmt":"2013-04-25T17:54:27","slug":"read-a-changelog-from-an-rpm-file","status":"publish","type":"post","link":"https:\/\/www.popmartian.com\/tipsntricks\/2013\/04\/25\/read-a-changelog-from-an-rpm-file\/","title":{"rendered":"Read a Changelog From an RPM File"},"content":{"rendered":"<p>The internet is full of tips on how to read the changelog from an RPM package you have installed.<\/p>\n<p>How do you read the changelog from a .rpm file before you install it?<\/p>\n<p>The answer is amazingly simple:<\/p>\n<p><code>rpm -q --changelog -p \/path\/to\/file.rpm<\/code><\/p>\n<p>Anything you can query from an installed package with rpm -q you can query from a file with -p.<\/p>\n<p>So why is the answer hard so to find?  Because the rpm man page describes <code>-p,--package PACKAGE_FILE<\/code> under select-options, but leaves it out under query-options.<\/p>\n<p>The fact that there is a curly brace where there should be a square bracket tells me the maintainers of this man page don&#8217;t actually use it.<\/p>\n<p><code><br \/>\n   select-options<br \/>\n        [PACKAGE_NAME] [-a,--all] [-f,--file FILE]<br \/>\n        [-g,--group GROUP] {-p,--package PACKAGE_FILE]<br \/>\n        [--fileid MD5] [--hdrid SHA1] [--pkgid MD5] [--tid TID]<br \/>\n        [--querybynumber HDRNUM] [--triggeredby PACKAGE_NAME]<br \/>\n        [--whatprovides CAPABILITY] [--whatrequires CAPABILITY]<\/p>\n<p>   query-options<br \/>\n        [--changelog] [-c,--configfiles] [-d,--docfiles] [--dump]<br \/>\n        [--filesbypkg] [-i,--info] [--last] [-l,--list]<br \/>\n        [--provides] [--qf,--queryformat QUERYFMT]<br \/>\n        [-R,--requires] [--scripts] [-s,--state]<br \/>\n        [--triggers,--triggerscripts]<br \/>\n<\/code><\/p>\n<p>Did you catch that?<\/p>\n<p>Under select-options <strong>{<\/strong>-p,&#8211;package PACKAGE_FILE] should read <strong>[<\/strong>-p,&#8211;package PACKAGE_FILE] and the package flag should be under query-options as well.<\/p>\n<p>You can file the bug report. I have work to do.<\/p>\n<blockquote><p>Did you find this post useful or have questions or comments?  Please let  me know!<\/p><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>The internet is full of tips on how to read the changelog from an RPM package you have installed. How do you read the changelog from a .rpm file before you install it? The answer is amazingly simple: rpm -q &hellip; <a href=\"https:\/\/www.popmartian.com\/tipsntricks\/2013\/04\/25\/read-a-changelog-from-an-rpm-file\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,27,64],"tags":[],"class_list":["post-247","post","type-post","status-publish","format-standard","hentry","category-how-to-do-stuff","category-linux","category-rpm"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.popmartian.com\/tipsntricks\/wp-json\/wp\/v2\/posts\/247","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.popmartian.com\/tipsntricks\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.popmartian.com\/tipsntricks\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.popmartian.com\/tipsntricks\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.popmartian.com\/tipsntricks\/wp-json\/wp\/v2\/comments?post=247"}],"version-history":[{"count":6,"href":"https:\/\/www.popmartian.com\/tipsntricks\/wp-json\/wp\/v2\/posts\/247\/revisions"}],"predecessor-version":[{"id":253,"href":"https:\/\/www.popmartian.com\/tipsntricks\/wp-json\/wp\/v2\/posts\/247\/revisions\/253"}],"wp:attachment":[{"href":"https:\/\/www.popmartian.com\/tipsntricks\/wp-json\/wp\/v2\/media?parent=247"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.popmartian.com\/tipsntricks\/wp-json\/wp\/v2\/categories?post=247"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.popmartian.com\/tipsntricks\/wp-json\/wp\/v2\/tags?post=247"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}