Skip to content

Commit

Permalink
Naming consistency for arguments of subcommands.
Browse files Browse the repository at this point in the history
  • Loading branch information
amanjeev committed Jan 31, 2025
1 parent 2f15eaf commit 75637f9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions crates/criticalup-cli/src/cli/subcommand/which.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ use tracing::Span;
#[derive(Debug, Parser)]
pub(crate) struct Which {
/// Name of the binary to find the absolute path of
binary: String,
command: String,
/// Path to the manifest `criticalup.toml`
#[arg(long)]
project: Option<PathBuf>,
Expand All @@ -41,7 +41,7 @@ impl CommandExecute for Which {
let bin_path = PathBuf::from("bin");

let mut tool_executable = PathBuf::new();
tool_executable.set_file_name(&self.binary);
tool_executable.set_file_name(&self.command);

let tools_bin_path = abs_installation_dir_path.join(bin_path.join(&tool_executable));

Expand All @@ -60,7 +60,7 @@ impl CommandExecute for Which {
}
}
#[cfg(not(windows))]
return Err(BinaryNotInstalled(self.binary));
return Err(BinaryNotInstalled(self.command));
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ stderr
Display which binary will be run for a given command

Usage:
criticalup-test which [OPTIONS] <BINARY>
criticalup-test which [OPTIONS] <COMMAND>

Arguments:
<BINARY> Name of the binary to find the absolute path of
<COMMAND> Name of the binary to find the absolute path of

Options:
--project <PROJECT> Path to the manifest `criticalup.toml`
Expand Down

0 comments on commit 75637f9

Please sign in to comment.