Use -E sed parameter instead of -r.

BSD sed equivalent to -r parameter is -E and it is also supported in GNU
sed thus using -E results in support on both platforms.
This commit is contained in:
Piotr Esden-Tempski 2017-01-31 16:00:17 -08:00
parent 5541b42159
commit e3a12b57f5
1 changed files with 1 additions and 1 deletions

View File

@ -1,2 +1,2 @@
#!/bin/bash
for f in $( find . -name .gitignore ); do sed -re "s,^,find ${f%.gitignore} -name ',; s,$,' | xargs rm -f,;" $f; done | bash -v
for f in $( find . -name .gitignore ); do sed -Ee "s,^,find ${f%.gitignore} -name ',; s,$,' | xargs rm -f,;" $f; done | bash -v