Article From:https://www.cnblogs.com/rainboy2010/p/9216886.html

ZypperIt is the command line interface of OpenSUSE and enterprise package SUSE in Software Manager ZYpp. Mainly used in: 1. management software package: zypper can be used to install, delete, update and query local or remote packages. 2. management repository: zypper can be added to the command line,Delete, enable, or disable the library.

1. Installation package
Syntax: zypper install example: install Mozilla Firefox

zypper install MozillaFirefox

 

 2.Update package

Update a package: zypper update updates all packages: zypper update

View all available update list: zypper list-updates

3. Delete package

Syntax: zypper remove

4. Lookup package

Syntax: zypper search example: find all packages that start with GIT.

5. View the details of the package

Syntax: zypper info example: view the information of the curl

zypper info curl

6. Add libraries with zypper

Zypper addrepo, such as

zypper addrepo “http://download.opensuse.org/distribution/11.4/repo/oss/” “11.4”

Executing this command will generate 11.4.repo files in the /etc/zypp/repos.d directory, as follows:

7. View Library

 Syntax: zypper LR, zypper repos

Look at the complete URI:zypper LR –uri of repo

8. Search packets in the library

 Syntax: zypper search –repo XXX

9. Library renaming

For example, the command of the library 11.4 is suse:zypper renamerepo 11.4 suse

10. Delete Library

Remove the library with the removerepo option

11. Refresh Library

 Syntax: zypper refresh XXX

12. Modify library information

Such as auto refresh library 11.4:zypper modifyrepo –refresh 11.4

For example, disable library 11.4:zypper modifyrepo –disable 11.4

 

Link of this Article: Zypper common commands

Leave a Reply

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