How To Install libtie-cycle-perl on Debian 9

In this tutorial we learn how to install libtie-cycle-perl on Debian 9. libtie-cycle-perl is module for cycling through a list of values via a scalar

Introduction

In this tutorial we learn how to install libtie-cycle-perl on Debian 9.

What is libtie-cycle-perl

libtie-cycle-perl is:

You use Tie::Cycle to go through a list over and over again. Once you get to the end of the list, you go back to the beginning. You don’t have to worry about any of this since the magic of tie does that for you.

The tie takes an array reference as its third argument. The tie should succeed unless the argument is not an array reference. Previous versions required you to use an array that had more than one element (what’s the pointing of looping otherwise?), but I’ve removed that restriction since the number of elements you want to use may change depending on the situation.

During the tie, this module makes a shallow copy of the array reference. If the array reference contains references, and those references are changed after the tie, the elements of the cycle will change as well. See the included test.pl script for an example of this effect.

There are three methods to install libtie-cycle-perl on Debian 9. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install libtie-cycle-perl Using apt-get

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

sudo apt-get update

After updating apt database, We can install libtie-cycle-perl using apt-get by running the following command:

sudo apt-get -y install libtie-cycle-perl

Install libtie-cycle-perl Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install libtie-cycle-perl using apt by running the following command:

sudo apt -y install libtie-cycle-perl

Install libtie-cycle-perl 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 Debian. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install libtie-cycle-perl using aptitude by running the following command:

sudo aptitude -y install libtie-cycle-perl

How To Uninstall libtie-cycle-perl on Debian 9

To uninstall only the libtie-cycle-perl package we can use the following command:

sudo apt-get remove libtie-cycle-perl

Uninstall libtie-cycle-perl And Its Dependencies

To uninstall libtie-cycle-perl and its dependencies that are no longer needed by Debian 9, we can use the command below:

sudo apt-get -y autoremove libtie-cycle-perl

Remove libtie-cycle-perl Configurations and Data

To remove libtie-cycle-perl configuration and data from Debian 9 we can use the following command:

sudo apt-get -y purge libtie-cycle-perl

Remove libtie-cycle-perl configuration, data, and all of its dependencies

We can use the following command to remove libtie-cycle-perl configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge libtie-cycle-perl

Dependencies

libtie-cycle-perl have the following dependencies:

References

Summary

In this tutorial we learn how to install libtie-cycle-perl package on Debian 9 using different package management tools: apt, apt-get and aptitude.