yum Command: List The Contents (Files) Of A Package on Linux

To list the contents (files) of a package in Linux using yum, you can use the following command:

yum list <package-name>

This will show you a list of packages available in your repositories that match the specified package name. Once you have identified the correct package, you can use the following command to list the contents of the package:

yum list <package-name> -q --files

The -q option is used to reduce the verbosity of the output and the --files option shows a list of the files included in the package.

You can also use the following command to list the contents of an already installed package:

rpm -ql <package-name>

The -q option stands for “query” and the -l option lists the files in the package.

Leave a Comment