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
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
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
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