-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Closed
Labels
Description
date prints a wrong Error message when the --date flag has a wrong argument.
❯ ./target/debug/date --date "@$(date +%s)" q
date: invalid date 'q'
❯ gdate --date "@$(date +%s)" q
gdate: the argument ‘q’ lacks a leading '+';
when using an option to specify date(s), any non-option
argument must be a format string beginning with '+'
Try 'gdate --help' for more information.
If a second wrong argument is passed
❯ ./target/debug/date --date "@$(date +%s)" ab sa
date: extra operand 'sa'
❯ gdate --date "@$(date +%s)" ab sa
gdate: extra operand ‘sa’
Try 'gdate --help' for more information.
the first line is correct but it still misses the 'Try ... ' line.
Reactions are currently unavailable