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
I have read the troubleshooting section and still think this is a bug.
Describe the bug you encountered:
Thanks for fd, it comes in handy!
Attempts to use the shorthand -1 alias instead of --max-results with exec or batch exec are not prevented, and the operations will be performed on every object which matches the query instead of the first hit. Depending on what one was trying to achieve the impact of this can be quite significant.
The alias does not have the relevant conflicts_with
Finally -1 overrides_with --max-results, but not the other way around so fd --max-results=1 -1 -X prog query will launch prog against all objects matching query.
Describe what you expected to happen:
Consistent behavior: if mixing max-results with exec-type functions is refused, same should be true for aliases.
What version of fd are you using?
8.7.0
Which operating system / distribution are you on?
Linux
The text was updated successfully, but these errors were encountered:
Checks
Describe the bug you encountered:
Thanks for fd, it comes in handy!
Attempts to use the shorthand
-1
alias instead of--max-results
with exec or batch exec are not prevented, and the operations will be performed on every object which matches the query instead of the first hit. Depending on what one was trying to achieve the impact of this can be quite significant.The alias does not have the relevant
conflicts_with
fd/src/cli.rs
Lines 513 to 522 in 93cdb26
Using long option
--max-results=1
would yield immediate abort and explanation that options conflict:fd/src/cli.rs
Lines 20 to 30 in 93cdb26
Finally
-1
overrides_with--max-results
, but not the other way around sofd --max-results=1 -1 -X prog query
will launch prog against all objects matching query.Describe what you expected to happen:
Consistent behavior: if mixing
max-results
with exec-type functions is refused, same should be true for aliases.What version of
fd
are you using?8.7.0
Which operating system / distribution are you on?
The text was updated successfully, but these errors were encountered: