MacOS Support
MacOS sed
doesn't support -r
sed: illegal option -- r
usage: sed script [-Ealn] [-i extension] [file ...]
sed [-Ealn] [-i extension] [-e script] ... [-f script_file] ... [file ...]
Possible fixes:
- Detect macOS with
uname
and then rungsed
instead ofsed
. (Macgsed
is identical to "normal"sed
.) - Figure out how to run the sed command without
-r