Skip to content

Commit bbcea1f

Browse files
authored
fix(cli): improve error messages regarding cargo metadata command (#13918)
1 parent 5ba1c3f commit bbcea1f

File tree

1 file changed

+2
-2
lines changed
  • crates/tauri-cli/src/interface

1 file changed

+2
-2
lines changed

crates/tauri-cli/src/interface/rust.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1183,7 +1183,7 @@ pub(crate) fn get_cargo_target_dir(args: &[String]) -> crate::Result<PathBuf> {
11831183
std::env::current_dir()?.join(target)
11841184
} else {
11851185
get_cargo_metadata()
1186-
.with_context(|| "failed to get cargo metadata")?
1186+
.with_context(|| "failed to run 'cargo metadata' command to get target directory")?
11871187
.target_directory
11881188
};
11891189

@@ -1221,7 +1221,7 @@ fn get_cargo_option<'a>(args: &'a [String], option: &'a str) -> Option<&'a str>
12211221
pub fn get_workspace_dir() -> crate::Result<PathBuf> {
12221222
Ok(
12231223
get_cargo_metadata()
1224-
.context("failed to get cargo metadata")?
1224+
.context("failed to run 'cargo metadata' command to get workspace directory")?
12251225
.workspace_root,
12261226
)
12271227
}

0 commit comments

Comments
 (0)