ripgrep
From Gentoo Wiki
ripgrep is search tool that can recursively search directories for regex search patterns. ripgrep can replicate much of the functionality of the grep command, but has a generally wider scope.
Installation
USE flags
USE flags for sys-apps/ripgrep a search tool that combines the usability of ag with the raw speed of grep
Emerge
Install sys-apps/ripgrep:
root #
emerge --ask sys-apps/ripgrep
Usage
Invocation
To view ripgrep usage and options:
user $
rg --help
Search for a string in current directory
To recursively search files in the current directory for a string:
user $
rg <string>
Find a string in a file
Use ripgrep to find a string in a file:
user $
rg <string> <file>
Removal
Unmerge
Remove sys-apps/ripgrep:
root #
emerge --ask --depclean --verbose sys-apps/ripgrep
See also
- grep — a tool for searching text files with regular expressions