How To Install python-pyjavaproperties on Ubuntu 18.04

In this tutorial we learn how to install python-pyjavaproperties on Ubuntu 18.04. python-pyjavaproperties is Python implementation of java.util.Properties

Introduction

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

What is python-pyjavaproperties

python-pyjavaproperties is:

This module is designed to be a Python equivalent to the java.util.Properties class. Currently, the basic input/output methods are supported, and there are plans to add the XML input/output methods found in J2SE 5.0.

Fundamentally, this module is designed so that users can easily parse and manipulate Java Properties files - that’s it. There’s a fair number of Pythonistas who work in multi-language shops, and constantly writing your own parsing mechanism is just painful. Not to mention Java guys are notoriously unwilling to use anything which is cross-language for configuration, unless it’s XML, which is a form of self-punishment. :)

There are three methods to install python-pyjavaproperties 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-pyjavaproperties 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-pyjavaproperties using apt-get by running the following command:

sudo apt-get -y install python-pyjavaproperties

Install python-pyjavaproperties Using apt

Update apt database with apt using the following command.

sudo apt update

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

sudo apt -y install python-pyjavaproperties

Install python-pyjavaproperties 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-pyjavaproperties using aptitude by running the following command:

sudo aptitude -y install python-pyjavaproperties

How To Uninstall python-pyjavaproperties on Ubuntu 18.04

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

sudo apt-get remove python-pyjavaproperties

Uninstall python-pyjavaproperties And Its Dependencies

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

sudo apt-get -y autoremove python-pyjavaproperties

Remove python-pyjavaproperties Configurations and Data

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

sudo apt-get -y purge python-pyjavaproperties

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

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

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

References

Summary

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