feat: enhance dependency handling in install process and update repo key trust prompt
This commit is contained in:
+14
-12
@@ -1876,6 +1876,7 @@ fn install_planned_packages_to_rootfs(
|
||||
is_update: plan.staged.is_update,
|
||||
});
|
||||
}
|
||||
install::scripts::run_deferred_hooks_if_possible(rootfs)?;
|
||||
Ok(installed)
|
||||
}
|
||||
|
||||
@@ -4885,6 +4886,19 @@ pub fn run(cli: Cli) -> Result<()> {
|
||||
"Missing dependencies: {}",
|
||||
missing_required.join(", ")
|
||||
));
|
||||
if !install_deps {
|
||||
if dry_run {
|
||||
ui::info(
|
||||
"Dry run enabled, stopping before dependency installation/build.",
|
||||
);
|
||||
return Ok(());
|
||||
}
|
||||
anyhow::bail!(
|
||||
"Missing dependencies: {}. Re-run with --install-deps to install them automatically, or install them manually.",
|
||||
missing_required.join(", ")
|
||||
);
|
||||
}
|
||||
|
||||
let local_sibling_root = spec_path
|
||||
.parent()
|
||||
.and_then(|p| p.parent())
|
||||
@@ -4914,18 +4928,6 @@ pub fn run(cli: Cli) -> Result<()> {
|
||||
);
|
||||
}
|
||||
print_plan_summary(&dep_plan);
|
||||
if !install_deps {
|
||||
if dry_run {
|
||||
ui::info(
|
||||
"Dry run enabled, stopping before dependency installation/build.",
|
||||
);
|
||||
return Ok(());
|
||||
}
|
||||
anyhow::bail!(
|
||||
"Missing dependencies: {}. Re-run with --install-deps to install them automatically, or install them manually.",
|
||||
missing_required.join(", ")
|
||||
);
|
||||
}
|
||||
if dry_run {
|
||||
ui::info(
|
||||
"Dry run enabled, stopping before dependency installation/build.",
|
||||
|
||||
+1
-1
@@ -1061,7 +1061,7 @@ fn try_trust_repo_public_key_for_repo_db(
|
||||
repo_name,
|
||||
trusted_dir.display()
|
||||
);
|
||||
if !crate::ui::prompt_yes_no(&prompt, false)? {
|
||||
if !crate::ui::prompt_yes_no(&prompt, true)? {
|
||||
crate::log_warn!(
|
||||
"Skipped trusting repo key '{}' for binary repo '{}'",
|
||||
key_name,
|
||||
|
||||
Reference in New Issue
Block a user