bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#59533: BUG: files starting with "-" makes stat to say "invalid optio


From: Pádraig Brady
Subject: bug#59533: BUG: files starting with "-" makes stat to say "invalid option -- 'S'" #64
Date: Thu, 24 Nov 2022 13:12:25 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.0

tag 59533 notabug
close 59533
stop

On 23/11/2022 19:34, Elias Tsolis wrote:
files starting with "-" makes stat to say "invalid option -- 'S'"

example, create a file "-fddsfdf.txt" and run "stat *" or "stat
-fddsfdf.txt"

and then again , create a file "fddsfdf.txt" and run "stat *" or "stat
fddsfdf.txt"

In first case, it will says "invalid option -- 'S'",
in second, it will be run normally.

This is usually handled with:
  stat ./-blah
  stat -- -blah

thanks,
Pádraig





reply via email to

[Prev in Thread] Current Thread [Next in Thread]