Use sudo and don't try to prompt on no-confirm
This commit is contained in:
parent
d900830f04
commit
47ae6398f8
8
.github/workflows/ci.yml
vendored
8
.github/workflows/ci.yml
vendored
|
@ -135,13 +135,13 @@ jobs:
|
||||||
with:
|
with:
|
||||||
name: harmonic-x86_64-darwin
|
name: harmonic-x86_64-darwin
|
||||||
- name: Initial install
|
- name: Initial install
|
||||||
run: ./harmonic install darwin-multi --no-confirm
|
run: sudo ./harmonic install darwin-multi --no-confirm
|
||||||
- name: Test run
|
- name: Test run
|
||||||
run: nix run nixpkgs#fortune
|
run: nix run nixpkgs#fortune
|
||||||
- name: Initial uninstall
|
- name: Initial uninstall
|
||||||
run: ./harmonic uninstall --no-confirm
|
run: sudo ./harmonic uninstall --no-confirm
|
||||||
- name: Repeated install
|
- name: Repeated install
|
||||||
run: ./harmonic install darwin-multi --no-confirm
|
run: sudo ./harmonic install darwin-multi --no-confirm
|
||||||
- name: Repeated uninstall
|
- name: Repeated uninstall
|
||||||
run: ./harmonic uninstall --no-confirm
|
run: sudo ./harmonic uninstall --no-confirm
|
||||||
|
|
|
@ -61,8 +61,10 @@ impl CommandExecute for Install {
|
||||||
|
|
||||||
if let Err(err) = plan.install().await {
|
if let Err(err) = plan.install().await {
|
||||||
tracing::error!("{:?}", eyre!(err));
|
tracing::error!("{:?}", eyre!(err));
|
||||||
if !interaction::confirm(plan.describe_revert(explain)).await? {
|
if !no_confirm {
|
||||||
interaction::clean_exit_with_message("Okay, didn't do anything! Bye!").await;
|
if !interaction::confirm(plan.describe_revert(explain)).await? {
|
||||||
|
interaction::clean_exit_with_message("Okay, didn't do anything! Bye!").await;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
plan.revert().await?
|
plan.revert().await?
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue