How To Install ruby-jar-dependencies on Ubuntu 18.04

In this tutorial we learn how to install ruby-jar-dependencies on Ubuntu 18.04. ruby-jar-dependencies is manage jar dependencies for Ruby gems

Introduction

In this tutorial we learn how to install ruby-jar-dependencies on Ubuntu 18.04.

What is ruby-jar-dependencies

ruby-jar-dependencies is:

jar-dependencies gem provides a simple way to load jars into JRuby’s classloader. It also has additional and very convenient features like: allowing to declare jar dependencies in the gemspec files, vendoring jars with gems if needed, reuse jar files from Maven local repositories, lock down specific jar versions to avoid conflicts and support for proxy and mirrors functionalities thanks to a close integration with Maven.

The idea behind jar-dependencies is to do jar dependencies management in a correct way. It’s somehow similar to the bundler tool but for jars.

There are three methods to install ruby-jar-dependencies 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 ruby-jar-dependencies Using apt-get

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

sudo apt-get update

After updating apt database, We can install ruby-jar-dependencies using apt-get by running the following command:

sudo apt-get -y install ruby-jar-dependencies

Install ruby-jar-dependencies Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install ruby-jar-dependencies using apt by running the following command:

sudo apt -y install ruby-jar-dependencies

Install ruby-jar-dependencies 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 ruby-jar-dependencies using aptitude by running the following command:

sudo aptitude -y install ruby-jar-dependencies

How To Uninstall ruby-jar-dependencies on Ubuntu 18.04

To uninstall only the ruby-jar-dependencies package we can use the following command:

sudo apt-get remove ruby-jar-dependencies

Uninstall ruby-jar-dependencies And Its Dependencies

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

sudo apt-get -y autoremove ruby-jar-dependencies

Remove ruby-jar-dependencies Configurations and Data

To remove ruby-jar-dependencies configuration and data from Ubuntu 18.04 we can use the following command:

sudo apt-get -y purge ruby-jar-dependencies

Remove ruby-jar-dependencies configuration, data, and all of its dependencies

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

sudo apt-get -y autoremove --purge ruby-jar-dependencies

References

Summary

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