How To Install perl-CSS-Minifier on CentOS 7
Introduction
In this tutorial we learn how to install perl-CSS-Minifier
on CentOS 7.
What is perl-CSS-Minifier
This module removes unnecessary whitespace from CSS. The primary requirement developing this module is to not break working stylesheets output. The Mac/Internet Explorer comment hack will be minimized but not stripped and so will continue to function.This module understands space, horizontal tab, new line, carriage return, and form feed characters to be whitespace. Any other characters that may be considered whitespace are not minimized. These other characters include paragraph separator and vertical tab.For static CSS files, it is recommended that you minify during the build stage of web deployment. If you minify on-the-fly then it might be a good idea to cache the minified file. Minifying static files on-the-fly repeatedly is wasteful.
We can use yum
or dnf
to install perl-CSS-Minifier
on CentOS 7. In this tutorial we discuss both methods but you only need to choose one of method to install perl-CSS-Minifier.
Install perl-CSS-Minifier on CentOS 7 Using yum
Update yum database with yum
using the following command.
sudo yum makecache
After updating yum database, We can install perl-CSS-Minifier
using yum
by running the following command:
sudo yum -y install perl-CSS-Minifier
Install perl-CSS-Minifier on CentOS 7 Using dnf
If you don’t have dnf installed you can install DNF on CentOS 7 first.
Update yum database with dnf
using the following command.
sudo dnf makecache
After updating yum database, We can install perl-CSS-Minifier
using dnf
by running the following command:
sudo dnf -y install perl-CSS-Minifier
How To Uninstall perl-CSS-Minifier on CentOS 7
To uninstall only the perl-CSS-Minifier
package we can use the following command:
sudo dnf remove perl-CSS-Minifier
References
Summary
In this tutorial we learn how to install perl-CSS-Minifier
on CentOS 7 using yum
and dnf
.