SBdocs - SlackBuilder Tutorials - pkg-info

Last updated:

pkg-info


Examples of use

Get the USAGE message with either 'pkg-info -h' or just 'pkg-info' with no options.

--> pkg-info -h

  pkg-info [Option] [pkg] 
  Requires at least one switch and a pkg as an argument
    
    -u (update the pkg database)
    -I (returns basic pkg info)
    -m (returns the metadata header for pkg)
    -s (returns the source locatation of pkg)
    -P (lists all packages that match argument)
    -p (returns the highest version package available that matches pkg name)
    -d (gets a list of dependecies for pkg -- non recursive)
    -R (looks to see if pkg is a requirement of another pkg and
       returns that pkg name)
    -i (if installed returns pkg)
    -e (does the pkg exists? returns yes/no)
    -n (get the name portion of pkg)
    -v (get the version portion of pkg)
    -V (get version-ARCH-REV of a pkg. everything but the name)
    -l (find the repository sub directory location of pkg)
    -h (show this help message) 
  
  ------------------------------------------------------------------------

Update the packages database.

--> pkg-info -u
 HTTP:mirrors2.kernel.org/slackware/slackware64-14.2/PACKAGES.TXT
   650K .......... .......... .......... .......              100% 2.67M=0.5s
     0K .......... .......... .......... .                    100%  416K=0.07s
     0K .......... .......... ..                              100%  352K=0.06s
 HTTP:slackonly.com/pub/packages/14.2-x86_64/PACKAGES.TXT
  4200K ....                                                  100% 9270G=2.0s
 HTTP:linuxoutpost.com/repos/Slackbuilder-x86_64-14.2/PACKAGES.TXT
     0K .......... .......... .......... .......... ..        100%  468K=0.09s
 HTTP:localhost/Slackbuilder-noarch-all/PACKAGES.TXT
     0K ..........                                            100%  205M=0s

Get basic information about a package

--> pkg-info -I kodi
Name="kodi"
Location="./multimedia"
Version="16.1-x86_64-4_Skn"
Required="jdk,libass,libmpeg2,dcadec,crossguid,yajl,tinyxml,libmicrohttpd,libdvdcss"
Installed="kodi-16.1-x86_64-4_Skn.txz"

Show the metadata info on a package

--> pkg-info -m kodi


NAME:  kodi-16.1-x86_64-4_Skn.txz
SRC: HTTP:linuxoutpost.com/Slackbuilder-x86_64-14.2
LOCATION:  ./multimedia
SIZE (compressed):  24578 K
SIZE (uncompressed):  61540 K
REQUIRED:  jdk,libass,libmpeg2,dcadec,crossguid,yajl,tinyxml,libmicrohttpd,libdvdcss
CONFLICTS:  
SUGGESTS:  
DESCRIPTION:
kodi: kodi (Multi-platform Media Center)
kodi:
kodi: XBMC is an award winning media center application for Linux, Mac OS X,
kodi: Windows and XBox. The ultimate hub for all your media, XBMC is easy to
kodi: use, looks slick, and has a large helpful community.  XBMC supports
kodi: viewing and playing a vast library of audio, video and image formats.
kodi: XBMC has a sophisticated library management system that allows you to
kodi: organize all your media to give you quick and immediate access.
kodi:
kodi: Homepage: http://kodi.tv
kodi:


Show the source for a pkg

--> pkg-info -s kodi
HTTP:localhost/Slackbuilder-x86_64-14.2

List all packages that have the search term in the name

--> pkg-info -P kodi
kodi-16.1-x86_64-2_slonly.txz
kodi-16.1-x86_64-4_Skn.txz

Show the highest version of a package

--> pkg-info -p kodi
kodi-16.1-x86_64-4_Skn.txz

Show list of nonrecursive dependencies of a package

--> pkg-info -d kodi
jdk
libass
libmpeg2
dcadec
crossguid
yajl
tinyxml
libmicrohttpd
libdvdcss

List all upline packages that lists a package as its dependency

--> pkg-info -R jdk 
EMBOSS-6.6.0-x86_64-2_slonly.txz
GeoGebra-5.0.253.0-x86_64-2_slonly.txz
ImageJ-1.50-noarch-2_slonly.txz
archeopteryx-0.9901_beta-noarch-2_slonly.txz
.
.
.
.
.
webmin-1.820-noarch-1_slonly.txz
zookeeper-3.4.6-x86_64-2_slonly.txz
kodi-16.1-x86_64-4_Skn.txz

Show just the version of a package

--> pkg-info -v kodi
16.1

Show long version of a package including the arch and revision

--> pkg-info -V kodi
16.1-x86_64-4_Skn.txz

The location directory of a package in the repository

--> pkg-info -l kodi
multimedia

Comment in the Forum.

© 2015 - 2018  -   SlackBuilder  -   All Rights Reserved.

By: Lance Peterson -- Slackerson