How To Install python-beanbag on Ubuntu 18.04

In this tutorial we learn how to install python-beanbag on Ubuntu 18.04. python-beanbag is Helper module for accessing REST APIs - python2

Introduction

In this tutorial we learn how to install python-beanbag on Ubuntu 18.04.

What is python-beanbag

python-beanbag is:

BeanBag is a simple module that lets you access REST APIs in an easy way. See http://beanbag.readthedocs.org/ for more information.

This package installs the library for Python 2.

There are three methods to install python-beanbag on Ubuntu 18.04. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install python-beanbag Using apt-get

Update apt database with apt-get using the following command.

sudo apt-get update

After updating apt database, We can install python-beanbag using apt-get by running the following command:

sudo apt-get -y install python-beanbag

Install python-beanbag Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install python-beanbag using apt by running the following command:

sudo apt -y install python-beanbag

Install python-beanbag Using aptitude

If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Ubuntu. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install python-beanbag using aptitude by running the following command:

sudo aptitude -y install python-beanbag

How To Uninstall python-beanbag on Ubuntu 18.04

To uninstall only the python-beanbag package we can use the following command:

sudo apt-get remove python-beanbag

Uninstall python-beanbag And Its Dependencies

To uninstall python-beanbag and its dependencies that are no longer needed by Ubuntu 18.04, we can use the command below:

sudo apt-get -y autoremove python-beanbag

Remove python-beanbag Configurations and Data

To remove python-beanbag configuration and data from Ubuntu 18.04 we can use the following command:

sudo apt-get -y purge python-beanbag

Remove python-beanbag configuration, data, and all of its dependencies

We can use the following command to remove python-beanbag configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge python-beanbag

References

Summary

In this tutorial we learn how to install python-beanbag package on Ubuntu 18.04 using different package management tools: apt, apt-get and aptitude.