Fuzzy text searches with agrep

Conclusions

Agrep expands the search horizons and options for action: If you use this program in your scripts, you will often have access to additional convenience that you would not otherwise achieve without unreasonable overhead. However, even when used interactively (e.g., in the Shell), agrep proves to be a genuine asset, such as when you use -B to view the best results.

Infos

  1. Levenshtein distance: https://en.wikipedia.org/wiki/Levenshtein_distance
  2. Levenshtein algorithm: http://www.levenshtein.net
  3. agrep (Glimpse variant): ftp://ftp.cs.arizona.edu/agrep/
  4. Glimpse: https://en.wikipedia.org/wiki/GLIMPSE
  5. "Desktop Search with Recoll" by Karsten Günther, Linux Pro Magazine, issue 136, March 2012, pg. 88
  6. agrep repo on GitHub: https://github.com/Wikinaut/agrep
  7. TRE variant: http://laurikari.net/tre/download/
  8. Info on agrep: http://www.tgries.de/agrep
  9. ding: http://manpages.ubuntu.com/manpages/hardy/man1/ding.1.html

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy Linux Magazine

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

  • Command Line – tre-agrep

    Tre-agrep has all of grep's functionality but can also do ambiguous or fuzzy searches without deep knowledge of regular expressions.

  • Charly's Column: Biabam and Tre-agrep

    Most of the tools that show up in this column are small, smart, fast, and easily explained. This month is no exception; we feature a dynamic duo of tools.

  • ICgrep

    One of the most common tasks when working on computers involves browsing texts for search patterns. Here, ICgrep offers a modern, parallel, and Unicode-enabled alternative to the classic grep.

  • McFly

    When it comes to working at the command line, using Bash history effectively can save you time. McFly extends the Bash history's features and helps you find past commands more quickly.

  • Command Line: Grep

    Once you understand the intricacies of grep, you can find just about anything.

comments powered by Disqus

Direct Download

Read full article as PDF:

Price $2.95

News