How To Install libhtml-html5-sanity-perl on Kali Linux

In this tutorial we learn how to install libhtml-html5-sanity-perl on Kali Linux. libhtml-html5-sanity-perl is make HTML5 DOM trees less insane

Introduction

In this tutorial we learn how to install libhtml-html5-sanity-perl on Kali Linux.

What is libhtml-html5-sanity-perl

libhtml-html5-sanity-perl is:

HTML::HTML5::Sanity is a Perl library tidying HTML::HTML5::Parser.

The Document Object Model (DOM) generated by HTML::HTML5::Parser meets the requirements of the HTML5 spec, but will probably catch a lot of people by surprise.

The main oddity is that elements and attributes which appear to be namespaced are not really. For example, the following element:

...

Looks like it should be parsed so that it has an attribute “lang” in the XML namespace. Not so. It will really be parsed as having the attribute “xml:lang” in the null namespace.

There are three methods to install libhtml-html5-sanity-perl on Kali Linux. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install libhtml-html5-sanity-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 libhtml-html5-sanity-perl using apt-get by running the following command:

sudo apt-get -y install libhtml-html5-sanity-perl

Install libhtml-html5-sanity-perl Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install libhtml-html5-sanity-perl using apt by running the following command:

sudo apt -y install libhtml-html5-sanity-perl

Install libhtml-html5-sanity-perl Using aptitude

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

sudo aptitude update

After updating apt database, We can install libhtml-html5-sanity-perl using aptitude by running the following command:

sudo aptitude -y install libhtml-html5-sanity-perl

How To Uninstall libhtml-html5-sanity-perl on Kali Linux

To uninstall only the libhtml-html5-sanity-perl package we can use the following command:

sudo apt-get remove libhtml-html5-sanity-perl

Uninstall libhtml-html5-sanity-perl And Its Dependencies

To uninstall libhtml-html5-sanity-perl and its dependencies that are no longer needed by Kali Linux, we can use the command below:

sudo apt-get -y autoremove libhtml-html5-sanity-perl

Remove libhtml-html5-sanity-perl Configurations and Data

To remove libhtml-html5-sanity-perl configuration and data from Kali Linux we can use the following command:

sudo apt-get -y purge libhtml-html5-sanity-perl

Remove libhtml-html5-sanity-perl configuration, data, and all of its dependencies

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

sudo apt-get -y autoremove --purge libhtml-html5-sanity-perl

Dependencies

libhtml-html5-sanity-perl have the following dependencies:

References

Summary

In this tutorial we learn how to install libhtml-html5-sanity-perl package on Kali Linux using different package management tools: apt, apt-get and aptitude.