On 12/30/19 9:54 AM, Stephane Chazelas wrote:
> Please consider making it
> 
> 
> grep -l -- 'main' *.c
> 
> to raise awareness and try and teach people "the right way".

Interactively, I invariably use 'grep foo *.c' without the '--' and it works
just fine because the files under my control have names that do not start with
'-'. This is standard practice and simplifies the common-usage examples. So
although '--' should (and does) appear in examples to document a defensive
measure for scripts that must work even in nonstandard environments, '--'
needn't be used in examples everywhere that it could conceivably apply.



Reply via email to