Skip to content

Commit bdfa765

Browse files
committed
update usage of SUDO_ASKPASS -> NH_SUDO_ASKPASS
with reference to #261 (comment)
1 parent 14182c2 commit bdfa765

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/commands.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@ impl Command {
8383
Exec::cmd("sudo")
8484
};
8585

86-
// use SUDO_ASKPASS program for sudo if present
87-
let cmd = if std::env::var("SUDO_ASKPASS").is_ok() {
86+
// use NH_SUDO_ASKPASS program for sudo if present
87+
let cmd = if std::env::var("NH_SUDO_ASKPASS").is_ok() {
8888
cmd.arg("-A")
8989
} else {
9090
cmd

src/main.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,8 @@ fn self_elevate() -> ! {
5555
use std::os::unix::process::CommandExt;
5656

5757
let mut cmd = std::process::Command::new("sudo");
58-
// use SUDO_ASKPASS program for sudo if present
59-
if std::env::var("SUDO_ASKPASS").is_ok() {
58+
// use NH_SUDO_ASKPASS program for sudo if present
59+
if std::env::var("NH_SUDO_ASKPASS").is_ok() {
6060
cmd.arg("-A");
6161
}
6262

0 commit comments

Comments
 (0)