bug#54174: (MacOS Monterey 12.2.1: zsh): grep "string" * is interpreted as grep -V when directory has a filename "-Vfilename.ext"

2022-02-26 Thread Marja Koivunen
I had a directory with filenames that started with “-“ doing grep on that directory for a “string" did not find anything although “string was on some of the files” grep just kept repeating something … FreeBSD Finally, (with some help) I understood that grep interpreted “-Vfiename” as an option

bug#54174: (MacOS Monterey 12.2.1: zsh): grep "string" * is interpreted as grep -V when directory has a filename "-Vfilename.ext"

2022-02-26 Thread Bob Proulx
close 54174 thanks Marja Koivunen wrote: > I had a directory with filenames that started with "-" Of course that is okay. However it is unusual. And it means you need to be extra careful in handling it such as to avoid it being confused with an option. > doing grep on that directory for a "str

bug#54174: (MacOS Monterey 12.2.1: zsh): grep "string" * is interpreted as grep -V when directory has a filename "-Vfilename.ext"

2022-02-26 Thread sur-behoffski
On 2/27/22 05:03, Marja Koivunen wrote: > I had a directory with filenames that started with “-“ > > doing grep on that directory for a “string" did not find anything > although “string was on some of the files” > > grep just kept repeating something … FreeBSD > > Finally, (with some help) I und

bug#54174: (MacOS Monterey 12.2.1: zsh): grep "string" * is interpreted as grep -V when directory has a filename "-Vfilename.ext"

2022-02-26 Thread Gary Johnson
On 2022-02-26, Marja Koivunen wrote: > I had a directory with filenames that started with “-“ > > doing grep on that directory for a “string" did not find anything > although “string was on some of the files” > > grep just kept repeating something … FreeBSD > > Finally, (with some help) I unders