Ceci est une ancienne révision du document !
Table des matières
slackpkg
Slackpkg est un outil automatisé dédié à la gestion des paquets locaux et qui permet d'installer de nouveaux paquets via le réseau. Aujourd'hui, slackpkg fait partie intégrante de la Slackware, mais s'il n'est pas installé, vous pouvez télécharger la dernière version à partir de SourceForge et l'installer avec installpkg.
Configuration
Avant d'utiliser slackpkg, il est nécessaire d'avoir une liste actualisée des paquets avec indication de leurs versions, liste que slackpkg lui-même peut télécharger automatiquement dès lors qu'un site miroir (et un seul) a été défini. Pour sélectionner un miroir, dé-commentez simplement la ligne contenant une URL dans le fichier /etc/slackpkg/mirrors
. Notez que les liens sont classés par versions de la Slackware, assurez-vous que le lien sélectionné concerne bien la version installée sur votre système.
Puis exécutez:
darkstar~# slackpkg update gpg
L'étape suivante consiste à mettre à jour la liste de paquets par la commande:
darkstar~# slackpkg update
S'il n'y a pas eu de changement dans la liste, il vous sera demandé:
No changes in ChangeLog.txt between your last update and now. Do you really want to download all other files (y/N)?
Sinon slackpkg va télécharger et copier la liste la plus récente des informations sur les paquets, et l'utilisera.
Mise en liste noire
slackpackage se conformera au contenu du fichier /etc/slackpkg/blacklist. Par exemple, les motifs suivants éviteront tout paquet installé depuis le dépôt SBo ainsi que depuis le dépôt d'alienBob :
[0-9]+_SBo [0-9]+alien
Utilisation
L'emploi de motifs permet à Slackpkg de chercher, installer ou enlever des paquets. Slackpkg trouve tout paquet offrant une correspondance entre son nom complet lu dans la liste des paquets et le motif utilisé.
Recherche
La recherche d'un paquet vous indiquera son nom complet, sa version et s'il est installé ou non.
darkstar~# slackpkg search mc Looking for mc in package list. Please wait... DONE The list below shows all packages with name matching "mc". [ installed ] - mcelog-1.0pre3-i486-1 [uninstalled] - pcmciautils-017-i486-1 [ installed ] - mc-4.8.1.3-i486-1 [ installed ] - libmcrypt-2.5.8-i486-1
recherche de fichier
Recherche d'un fichier particulier afin d'installer ou enlever ultérieurement le(s) paquet(s) contenant ce fichier:
darkstar~# slackpkg file-search sshd Looking for sshd in package list. Please wait... DONE The list below shows the packages that contains "sshd" file. [ installed ] - openssh-6.0p1-i486-2
info
To get information about a package slackpkg Info packagename
will print the package's information to the screen.
install
To install a package use slackpkg install pattern
. If a package was found a dialog window will present any packages that matches to the pattern and the user can un/check which packages to install.
To install everything in a branch you can type: slackpkg install branch
for example slackpkg install kde
will install everything under kde (but nothing from kdei).
remove
To remove a package use slackpkg remove pattern
. If a package was found a dialog window will present any packages that matches to the pattern and the user can un/check which packages to remove.
upgrade
If an update is available for a certain package, it can be updated with slackpkg upgrade packagename
.
reinstall
This command can be used if a package became broken and needs to be re-installed.
blacklist
This can be used to add a certain package to the blacklist. Blacklisted packages are being disregarded by slackpkg.
generate-template
If you need to re-install the entire system or install a new PC that will have similar installed packages, a user can generate a template to be installed later.
install-template
This command is used to have all the packages in a template be installed on this PC.
install-new
Running slackpkg with this argument generates a list of packages that were introduces to the Slackware recently, for example new dependencies to a package. It is advisable to run this command before updating the system if you synchronize to slackware-current.
upgrade-all
Running slackpkg with this argument will generate a list of all packages that can be upgraded with a new version. The user can un/check which packages to upgrade from a dialog list.
clean-system
Running slackpkg with this argument will generate a list of all packages that are obsolete and can be safely removed from the system. Note that non-official packages will be listed here unless blacklisted.
new-config
During installation a new configuration file might be installed and overwrite your configurations. To prevent that the file will receive a “.new” prefix and after installation slackpkg will inform the user about the existence of these files. Running slackpkg with this argument will search for the existence of these files and will ask the user for instructions.
check-updates
Running slackpkg with this argument will produce a clean printout if there are any available updates.
Full system upgrade
To perform a full system upgrade, please follow these steps (as root user):
slackpkg update slackpkg install-new slackpkg upgrade-all slackpkg clean-system
It is always recommended to read the latest ChangeLogs and UPGRADING.TXT
(found on the HTTP/FTP mirrors for each version) before doing any major system upgrades.
External Links
- SlackPKG home page: http://www.slackpkg.org/
- SlackPKG project on SourceForge: http://sourceforge.net/projects/slackpkg/
Sources