apt get command in linux to manage packages in your system | Pro Tech guides

apt get command in linux to manage packages in your system

apt-get command in linux allows you to update, install, remove packages/software in your linux system. You can also remove unwanted junk libraries

apt get command in linux to update, install, remove and manage packages

apt-get command in linux
apt-get command in linux

Hello guys, Today I'm going to show you how you can use the "apt" command in linux. To Install, Remove and Manage packages in Debian based operating system.

Most of the Debian based operating system you can use "apt" command to install, remove and update packages in your system.


What is "apt" command?

"apt" is a command-line tool for working with an apt software package.

apt (Advanced Package Tool) available in Debian based operating system.

You need superuser privilege to use "apt" command so just use "sudo apt" because you are managing your packages in your system.

There are a bunch of commands which you can use with "apt",

Update all Packages

sudo apt update command in linux
Update all Packages in your System


$sudo apt update
This command is going to re-synchronize your local package files to the remote server.

These package files are saved in a file called "sources.list". Which is in the location of "etc/apt/sources.list".


Install software/package

sudo apt install command in linux
Install a Package in Linux


$sudo apt install packageName

For example, I want to install a package called "git". So I just need to type "sudo apt install git" and press ENTER.


apt install
Example

This command recognizes whatever extra software and dependencies this "git" package requires.

It's going to make a list of dependencies and software and also going to show you the amount of disk space it takes from your computer.

For example, This "git" requires "50.5 MB" of memory on my system and it going to ask whether you want to install it or not.

If you want to install it type "y" and press ENTER. Otherwise, type "n".

It takes some time depending on your internet speed to install.

Check Version

version flag in linux
Check Version

$packageName --version
To check which version of software you have been installed by using a flag called "--version".

For example, Just say "git --version" and press ENTER. It will print the version.

Remove software/package

sudo apt-get remove command in linux
Remove Packages in linux


$sudo apt remove packageName

I want to remove the "git" package. So I just write "sudo apt remove git" and press ENTER. It's going to remove the package from my system.


Note:

But it's not going to remove configuratios from your system. It just remove the package only.


--purge flag

apt get remove --purge to remove all configuration in linux
Remove configuration files


$sudo apt remove --purge packageName

To remove the configurations you need to use "--purge" flag. So just write "sudo apt remove --purge git" press ENTER.

It's going to remove all configuration files related to this "git".

Remove unwanted libraries

sudo apt-get autoremove to remove unwanted files
Remove unwanted Libraries


$sudo apt autoremove
There are some libraries and software which are not used by their parent software.

For this, you can use "sudo apt autoremove" command to remove all unwanted dependencies and libraries which are no longer needed.

It asks for confirmation to remove. Before removing just check the above libraries which are really necessary for you.


Conclusion

In this way you can use the "apt" command for Installing, Removing software and dependencies.

There are more flags you can use with this "apt" command. But these are the most frequently used commands in "apt".

I hope you enjoyed this tutorial, THANK YOU.

HAVE A NICE DAY💖

See also,

Name

Apps,3,Games,1,Linux,38,Linux Commands,37,Network-Devices,1,Networking,1,Terminal Apps,2,Termux,17,Userland,3,Windows,1,
ltr
item
Pro Tech guides: apt get command in linux to manage packages in your system
apt get command in linux to manage packages in your system
apt-get command in linux allows you to update, install, remove packages/software in your linux system. You can also remove unwanted junk libraries
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg9KMyD-fyUTNvcoFijOF8Qy1hCO1OO1kfNEi6CJHI91vrKiAWhAcTLqcyog7oFsYkwr0jUTS21uoE7oJ_-_8HB8qNpvv4hi_8BGokmURpp6G2xV2Ne7LtArVAVXrk3k76VAOeRNGQS42k/s16000/apt-get-command-in-linux.png
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg9KMyD-fyUTNvcoFijOF8Qy1hCO1OO1kfNEi6CJHI91vrKiAWhAcTLqcyog7oFsYkwr0jUTS21uoE7oJ_-_8HB8qNpvv4hi_8BGokmURpp6G2xV2Ne7LtArVAVXrk3k76VAOeRNGQS42k/s72-c/apt-get-command-in-linux.png
Pro Tech guides
https://devops-digest.blogspot.com/2021/04/apt-get-command-in-linux-to-manage.html
https://devops-digest.blogspot.com/
https://devops-digest.blogspot.com/
https://devops-digest.blogspot.com/2021/04/apt-get-command-in-linux-to-manage.html
true
7053638852026728047
UTF-8
Loaded All Posts Not found any posts VIEW ALL Readmore Reply Cancel reply Delete By Home PAGES POSTS View All RECOMMENDED FOR YOU LABEL ARCHIVE SEARCH ALL POSTS Not found any post match with your request Back Home Sunday Monday Tuesday Wednesday Thursday Friday Saturday Sun Mon Tue Wed Thu Fri Sat January February March April May June July August September October November December Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec just now 1 minute ago $$1$$ minutes ago 1 hour ago $$1$$ hours ago Yesterday $$1$$ days ago $$1$$ weeks ago more than 5 weeks ago Followers Follow THIS PREMIUM CONTENT IS LOCKED STEP 1: Share to a social network STEP 2: Click the link on your social network Copy All Code Select All Code All codes were copied to your clipboard Can not copy the codes / texts, please press [CTRL]+[C] (or CMD+C with Mac) to copy Table of Content