bug(date): Mixing flags part 2, accepted
Open
Nobody has claimed this yet.
U - date
- Dominant language
- Rust
- Stars
- 24.1k
- Forks
- 2k
- Avg merge
- 1d 5h
- Merged PRs (30d)
- 365
Description
Hi, uutils mainteners
one thing i open a new issue instead staying with -s and -d one and updating the title is that one is a bad bug, these one not, so will be in part 2 whiches harmless
example 1 test
relunsec@relunsec:~/software/coreutils/target/debug$ ./date --rfc-3339 ns -R -d ""
Fri, 18 Sep 2026 00:00:00 -0400
relunsec@relunsec:~/software/coreutils/target/debug$ gnudate --rfc-3339 ns -R -d ""
gnudate: multiple output formats specified
relunsec@relunsec:~/software/coreutils/target/debug$
example test 2
relunsec@relunsec:~/software/coreutils/target/debug$ gnudate -r . -I +hours
gnudate: multiple output formats specified
relunsec@relunsec:~/software/coreutils/target/debug$ gnudate -r . -I hours
gnudate: the argument ‘hours’ lacks a leading '+';
when using an option to specify date(s), any non-option
argument must be a format string beginning with '+'
Try 'gnudate --help' for more information.
relunsec@relunsec:~/software/coreutils/target/debug$ ./date -r . -I hours
2026-09-18T07-04:00
relunsec@relunsec:~/software/coreutils/target/debug$
example test 3
relunsec@relunsec:~/software/coreutils/target/debug$ ./date -R -R -R
Fri, 18 Sep 2026 09:33:41 -0400
relunsec@relunsec:~/software/coreutils/target/debug$ ./date -R -R -R -R
Fri, 18 Sep 2026 09:33:43 -0400
relunsec@relunsec:~/software/coreutils/target/debug$ ./date -R -R -R -R -R
Fri, 18 Sep 2026 09:33:46 -0400
relunsec@relunsec:~/software/coreutils/target/debug$ gnudate -R -R -R -R -R
gnudate: multiple output formats specified
relunsec@relunsec:~/software/coreutils/target/debug$
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the date command's option parsing and output-format validation, using the three command-line examples and GNU date as the behavioral reference. Add regression coverage for conflicting formats, invalid format arguments, and repeated -R flags; done means the Rust date command reports the same conflicts and validation errors as gnudate.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 62/100