no-egrep
What it does
Section titled “What it does”Reports a call of egrep or fgrep.
Why it matters
Section titled “Why it matters”They are obsolescent wrappers of grep -E and grep -F, and recent versions of GNU grep warn about them. They are not in every system.
To fix, write grep -E or grep -F.
Example
Section titled “Example”...egrep x ffgrep x f...test -f x && echo yes || echo no...Configuration
Section titled “Configuration”shell: lint: rules: no-egrep: warn # off (default), warn, errorEnabled by the presets: shell/shellcheck.
Suppress one line with sudsy-disable-next-line no-egrep in a comment of the file’s language.
Upstream equivalents
Section titled “Upstream equivalents”The same check in other tools; Sudsy reports what each upstream rule reports.
| Tool | Rule | Match |
|---|---|---|
| shellcheck | SC2196 |
full |
| shellcheck | SC2197 |
full |