List licenses on a RPM based system

A couple times I’ve had to answer to question:  What licenses ship out with our system?  If you are shipping something on top of RedHat (in our case, CENTOS) or SuSE ( I haven’t tested this) you can generate a list of package names and licenses with the following command.

rpmquery -a –qf %-30{NAME}:%{LICENSE}”\n”

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.