How To Install grin on CentOS 7
Introduction
In this tutorial we learn how to install grin
on CentOS 7.
What is grin
grin is a similar in function to GNU grep, however it’s has modified behaviour to make it simpler to use when grepping source code. Some features grin feature are * recurse directories by default * do not go into directories with specified names * do not search files with specified extensions * be able to show context lines before and after matched lines * Python regex syntax * unless suppressed via a command line option, display the filename regardless of the number of files * accept a file (or stdin) with a list of newline-separated filenames * grep through gzipped text files * be useful as a library to build custom tools quickly
We can use yum
or dnf
to install grin
on CentOS 7. In this tutorial we discuss both methods but you only need to choose one of method to install grin.
Install grin on CentOS 7 Using yum
Update yum database with yum
using the following command.
sudo yum makecache
After updating yum database, We can install grin
using yum
by running the following command:
sudo yum -y install grin
Install grin 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 grin
using dnf
by running the following command:
sudo dnf -y install grin
How To Uninstall grin on CentOS 7
To uninstall only the grin
package we can use the following command:
sudo dnf remove grin
References
Summary
In this tutorial we learn how to install grin
on CentOS 7 using yum
and dnf
.