Solaris::Contents - Read /var/sadm/install/contents file
$c=Solaris::Contents::new();
Solaris::Contents is an object oriented interface into the /var/sadm/install/contents file which Solaris uses to keep track of all the files installed on a system, and their corresponding packages.
No arguements are required. By default, the object always believes the contents file is /var/sadm/install/contents. The ability to change this could change with a future release.
Returns an array of every file record in the contents file. Very long.
Returns an array of every file record for a specified package.
Returns a hash table of every element for a specified file.
Each of the above methods returns the specific data for a specified file entry from the contents file. Not all entries will have data specific to every method. Check the Solaris prototype man page for more information. The pkgs() method returns an array of packages related to that specific file.
The initialization time of Contents objects could take a few seconds depending on the size of the contents file.
I may add more methods to this class later on. It would be kind of neat to do more with the link entries.
Chris Josephes, chrisj@onvoy.com
To install Solaris::Package, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Solaris::Package
CPAN shell
perl -MCPAN -e shell install Solaris::Package
For more information on module installation, please visit the detailed CPAN module installation guide.