Skip to content

Commit 64c72d7

Browse files
committed
date: add date source option conflicts
1 parent 953f792 commit 64c72d7

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/uu/date/src/date.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -298,6 +298,7 @@ pub fn uu_app() -> Command {
298298
.long(OPT_FILE)
299299
.value_name("DATEFILE")
300300
.value_hint(clap::ValueHint::FilePath)
301+
.conflicts_with(OPT_DATE)
301302
.help(translate!("date-help-file")),
302303
)
303304
.arg(
@@ -315,6 +316,7 @@ pub fn uu_app() -> Command {
315316
.arg(
316317
Arg::new(OPT_RESOLUTION)
317318
.long(OPT_RESOLUTION)
319+
.conflicts_with_all([OPT_DATE, OPT_FILE])
318320
.overrides_with(OPT_RESOLUTION)
319321
.help(translate!("date-help-resolution"))
320322
.action(ArgAction::SetTrue),
@@ -347,6 +349,7 @@ pub fn uu_app() -> Command {
347349
.long(OPT_REFERENCE)
348350
.value_name("FILE")
349351
.value_hint(clap::ValueHint::AnyPath)
352+
.conflicts_with_all([OPT_DATE, OPT_FILE, OPT_RESOLUTION])
350353
.help(translate!("date-help-reference")),
351354
)
352355
.arg(

0 commit comments

Comments
 (0)