Skip to content

Commit

Permalink
fix: change threads short flag to -c in cli args to avoid conflict wi…
Browse files Browse the repository at this point in the history
…th `tree`
  • Loading branch information
ttys3 authored and marcospb19 committed Dec 14, 2024
1 parent e1d7f14 commit 28d0933
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/cli/args.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ pub struct CliArgs {
pub password: Option<OsString>,

/// cocurrent working threads
#[arg(short = 't', long, global = true)]
#[arg(short = 'c', long, global = true)]
pub threads: Option<usize>,

// Ouch and claps subcommands
Expand Down
2 changes: 2 additions & 0 deletions tests/snapshots/ui__ui_test_usage_help_flag-2.snap
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
source: tests/ui.rs
expression: "output_to_string(ouch!(\"-h\"))"
snapshot_kind: text
---
A command-line utility for easily compressing and decompressing files and directories.

Expand All @@ -21,5 +22,6 @@ Options:
-g, --gitignore Ignores files matched by git's ignore files
-f, --format <FORMAT> Specify the format of the archive
-p, --password <PASSWORD> decompress or list with password
-c, --threads <THREADS> cocurrent working threads
-h, --help Print help (see more with '--help')
-V, --version Print version
4 changes: 4 additions & 0 deletions tests/snapshots/ui__ui_test_usage_help_flag.snap
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
source: tests/ui.rs
expression: "output_to_string(ouch!(\"--help\"))"
snapshot_kind: text
---
A command-line utility for easily compressing and decompressing files and directories.

Expand Down Expand Up @@ -43,6 +44,9 @@ Options:
-p, --password <PASSWORD>
decompress or list with password

-c, --threads <THREADS>
cocurrent working threads

-h, --help
Print help (see a summary with '-h')

Expand Down

0 comments on commit 28d0933

Please sign in to comment.