Conda (Anaconda, Inc.) is an open-source dependency, package, and environment management system for any language such as Python, R, Javascript, C/C++, and so on. In this article, we are going to install Conda on Ubuntu 18.04 & 20.04.
Preparing system
Open a terminal by pressing Ctrl+Alt+T. Update and upgrade your system using the following commands:
$ sudo apt-get update
$ sudo apt-get upgrade
Downloading Conda
To install Conda, you will download Miniconda and Anaconda. At first, let’s install their installers.
Downloading Miniconda
For Miniconda, visit this link and identify an appropriate version of Python and Linux distribution installed on your system. We are installing the latest Linux installer. To download, paste the following command.
$ wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh
Downloading Anaconda
Visit this page to download or paste the following command in the terminal.
$ wget https://repo.anaconda.com/archive/Anaconda3-2021.05-Linux-x86_64.sh
Installing Conda
Before moving towards the installation of Conda, you will have to verify the downloaded installers as shown below.
$ sha256sum Miniconda3-latest-Linux-x86_64.sh
$ sha256sum Anaconda3-2021.05-Linux-x86_64.sh
Now, let’s install them.
Installing Miniconda
$ bash Miniconda3-latest-Linux-x86_64.sh
Follow the prompts. If unsure, then accept the defaults.
Installing Anaconda
$ bash Anaconda3-2021.05-Linux-x86_64.sh
Similarly, follow the prompts. It will take a few minutes to finish the installation.
To make changes take effect, close and re-open the terminal.
Testing the installation
Now type $ conda list
in the terminal, if it has been installed correctly, then it should display all installed packages.