current position:Home>The difference between apt and apt get

The difference between apt and apt get

2022-06-24 12:45:19Chen Bucheng I

One . brief introduction

**Ubuntu 16.04 A notable new feature of is apt Ordered “ introduce ”. in fact ,apt The first stable version of was in 2014 Published in , But as the Ubuntu 16.04 Release , People are 2016 Began to notice it in .

You usually see apt install package Not the usual apt-get install package. Final , Many other distributions follow Ubuntu And start encouraging users to use apt instead of apt-get.

You may want to know apt-get and apt What's the difference ? If they have a similar command structure , So new apt What is required for the command ? You may still be thinking about apt Is it better than apt-get Better ? You should use new apt The command still insists on using the old apt-get command ? I will explain all these issues in this article , I hope that at the end of this article , You will have a clearer understanding .

Two .apt vs apt-get

about Linux Mint Users , This is a simple statement . A few years ago ,Linux Mint Implemented a program called apt Of python Wrappers , It actually uses apt-get, But it offers more friendly options . The problem we are discussing here is related to Linux Mint Different problems in .

When we see apt and apt-get The difference between before , Let's take a look at the background of these commands and what they really want to achieve .

Why? apt First introduced ?

Debian,Ubuntu,Linux Mint, Master of the basic operating system and other distributions Linux, It has a powerful packaging system , Each component and application is built into a package installed on the system .Debian Use a group named Advanced Packaging Tool(APT) Tools to manage this packaging system . Don't associate it with commands apt confusion , It's different . There are various and APT Interactive tools , Allows you to use the Debian Of Linux Install... In the distribution , Delete and manage packages .

apt-get Is a widely popular command line tool . Another popular tool is have GUI And command line options Aptitude. If you have read about apt-get A guide to orders , You may encounter many similar commands , for example apt-cache. This is where the problem arises .

You see , The usage of these commands is too low , They have many functions , ordinary Linux Users may never have used . On the other hand , The most commonly used package management commands are distributed in apt-get and apt-cache in . The apt Package commands have been introduced to solve this problem .apt contain apt-get and apt-cache Some of the most widely used features in , In addition to blurring and rarely used features . It can also be managed apt.conf file . Use apt, You don't have to go from apt-get Order to apt-cache.apt More structured , Provides you with the necessary options for management packs .

Conclusion :apt = apt-get and apt-cache The most common command options in .

apt and apt-get The difference between

therefore , Use apt, You can get all the necessary tools in one place . You won't get lost in a lot of command options .apt The main purpose of is to “ Pleasant for end users ” Provides an efficient way to handle command packages .

When Debian say “ Very pleasant for the end user ” when , It actually means . It has fewer but enough command options , But in a more organized way . most important of all , By default, it enables some options that are actually useful to end users .

for example , You can go to apt View the progress bar when installing or removing programs in .

apt You will also be prompted for the number of packages that can be upgraded when updating the repository database .

If you use other command options , You can also use apt-get To achieve the same function .apt By default, they are enabled and pain is eliminated .

apt and apt-get The difference between orders

although apt There are indeed some with apt-get Similar command options , But it is not related to apt-get Backward compatibility . This means that if you just use apt Replace apt-get Ordered apt-get part , It will not always work . Let's see which apt The order replaced apt-get and apt-cache Command options

I should use apt still apt-get?

You may be wondering if you should use apt or apt-get.

  • As ordinary Linux user , My answer is with apt Use it together .
  • apt yes Linux Commands recommended by the distribution . It provides the necessary options for management packs . most important of all , Easier to use with fewer but easy to remember options .

Unless you want to use it apt-get Specific operations for more functions , Otherwise, I think there is no reason to insist on using apt-get.

3、 ... and . Conclusion

I wish I could explain apt and apt-get The difference between . Last , To sum up apt And apt-get The argument for :

  • apt yes apt-get and apt-cache A subset of commands , Provide necessary commands for package management
  • although apt-get Will not be abandoned , But as an ordinary user , You should start using more often apt

copyright notice
author[Chen Bucheng I],Please bring the original link to reprint, thank you.

Random recommended