How To Install sloccount on CentOS 7
Introduction
In this tutorial we learn how to install sloccount on CentOS 7.
What is sloccount
SLOCCount (pronounced “sloc-count”) is a suite of programs for counting physical source lines of code (SLOC) in potentially large software systems. SLOCCount can be used to generate reports in different formats for use by report-generating tools.
We can use yum or dnf to install sloccount on CentOS 7. In this tutorial we discuss both methods but you only need to choose one of method to install sloccount.
Install sloccount on CentOS 7 Using yum
Update yum database with yum using the following command.
sudo yum makecache
After updating yum database, We can install sloccount using yum by running the following command:
sudo yum -y install sloccount
Install sloccount 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 sloccount using dnf by running the following command:
sudo dnf -y install sloccount
How To Uninstall sloccount on CentOS 7
To uninstall only the sloccount package we can use the following command:
sudo dnf remove sloccount
References
Summary
In this tutorial we learn how to install sloccount on CentOS 7 using yum and dnf.