This is a basic Grep CLI implementation in Rust. It matches the main Regex expressions. This is a small research project.
- Ensure you have
cargo (1.76)
installed locally - In the terminal run
echo "sentence" | ./your_grep.sh -E "regex"
whereregex
is the pattern to match
Run echo "grep 101" | ./your_grep.sh -E "(\w+ \d\d\d)"
. The exit code will be the result.
Here you can find the Regex cheatsheet.
Run cargo test
to run the tests