Apt-GET command parameters in Ubuntu
Common apt Command Parameters
Apt-cache search package
Apt-Cache show package obtains package information, such as description, size, and version.
Sudo apt-Get install package installation package
Sudo apt-Get install package--reinstall re-installation package
Sudo apt-get-F install fix and install "-F =-fix-missing"
Sudo apt-Get remove package Delete package
Sudo apt-Get remove package--Purge delete a package, including deleting a configuration file.
Sudo apt-Get Update update source
Sudo apt-Get upgrade updates installed packages
Sudo apt-Get dist-upgrade System
Sudo apt-Get dselect-upgrade using dselect
Apt-Cache depends package for dependency usage
Apt-Cache rdepends package is used to check which packages are dependent on this package.
Sudo apt-Get build-dep package installation-related compilation environment
Apt-Get source package download the source code of the package
Sudo apt-Get Clean & sudo apt-Get autoclean clear useless packages
Sudo apt-Get check whether any corrupted dependency exists
Where:
1. If sudo exists, administrator privileges are required!
2. In ubuntu, the short parameter is "-", and the long parameter is "-".
3. You can use the man command to view the help information or
Command-H (--Help) to view
4. to exit the command in the man command, press "Q !!
Option description
Use Sudo-H help to list usage methods and exit.
Sudo-V version displays the version information and exits.
Sudo-l list lists the commands that can be executed by the current user. This option can only be used by users in sudoers.
Sudo-u username | # uid user executes commands as a specified user. The following users are not only root users, but also usernames or # UIDs.
Sudo-K kill clears the time on the "admission ticket" and enters the password next time you use sudo.
Sudo-K sure kill is similar to-K, but it also needs to tear up the "Admission volume", that is, delete the timestamp file.
Sudo-B command background executes the specified command in the background.
Sudo-P prompt command prompt can change the prompt message for asking the password, where % u is replaced by the user account name, and % H displays the host name. Very user-friendly design.
Sudo-e file edit is equivalent to sudoedit, instead of executing a command, but modifying a file.