Expand description
§SM: Self matching search patterns
Regex are great, but for small casual search operations, they can be pretty annoying.
Example: you want to search for the string getID("carl"). First, you need to escape the quotes.
Then, you might be unsure if it’s getID or getId, so you need case insensitivity. Or maybe it’s get_id?
Then you end up having to do a lot of edits to your search string to create a nice Regex. SM is optimized for
exactly these cases: A lazy developer searching for a code snippet in a messy code base.
Use cargo install sm-search to get the CLI tool. Or add this package with cargo add sm-search to use this
as your in your own programs. You can look at src/main.rs as example of how this library can be used.
Re-exports§
pub use sm_match::SM;