Skip to content

DiD92/rust-minigrep

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

minigrep - Rust grep parser tutorial tool

The original source for the tutorial can be found here

This version has an additional enhancement, it accepts an extra parameter to control wherever we ignore casing or not. Use it like this:

cargo run <search-query> <file> [I|K]

For example:

cargo run to poem.txt I

If the casing parameter is not present, mingrep will search for an environment variable called CASE_INSENSITIVE, the default behaviour is to keep the casing information on search.

Repo status

Rust