Add windows config for correct exe file name (#4985)
This commit is contained in:
1 parent
4fd7fe5511
commit
82d7802a81
1 file changed
+6
-1
@@ -159,7 +159,12 @@ impl SelfUpdate {
|
|||||||
.extract_into(&install_dir)
|
.extract_into(&install_dir)
|
||||||
.context("Failed to extract update")?;
|
.context("Failed to extract update")?;
|
||||||
|
|
||||||
let executable = install_dir.join("dx");
|
let exe = if cfg!(target_os = "windows") {
|
||||||
|
"dx.exe"
|
||||||
|
} else {
|
||||||
|
"dx"
|
||||||
|
};
|
||||||
|
let executable = install_dir.join(exe);
|
||||||
if !executable.exists() {
|
if !executable.exists() {
|
||||||
bail!("Executable not found in {}", install_dir.display());
|
bail!("Executable not found in {}", install_dir.display());
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user