You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The reason will be displayed to describe this comment to others. Learn more.
A clean solution would be to check if grep has -E option and if so use grep -E. For dinosaurs egrep can be used. "Obsolete" means this will be removed soon. So no workaraound but a solution would be the correct answer. grep --help | grep 'extended-regexp'
results in an empty string if -E is not available...
fe890c6
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry, why not
grep -E
?fe890c6
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In some old platforms,
grep
doesn't have a-E
option.fe890c6
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yup, that is my case (Asustor NAS) (Linux version 5.13.x (x86_64-asustor_x64_g3_2020.12.24-linux-gnu-gcc)
fe890c6
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A clean solution would be to check if grep has -E option and if so use grep -E. For dinosaurs egrep can be used. "Obsolete" means this will be removed soon. So no workaraound but a solution would be the correct answer.
grep --help | grep 'extended-regexp'
results in an empty string if -E is not available...