3 ms·
An alias also seems like it'd work. alias egrep='grep -E' alias fgrep='grep -F'
by williadc 4y ago
An alias also seems like it'd work.
alias egrep='grep -E'
alias fgrep='grep -F'
- chasil 4y agoPOSIX requires that aliases be observed in the context of a shell script, but there is a trap here. When bash is called as /bin/sh, it will be in POSIX mode, and will honor those aliases. When called as anything else or when otherwise not in POSIX mode, those aliases will fail. Bash was around for a decade before the POSIX shell standard was defined, so there is legacy baggage.