uutils / uutils/coreutils

bug(date): Mixing flags part 2, accepted

Open
#14,676 0 comments 0 reactions 0 assignees View on GitHub

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

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. 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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.