Rollup merge of #79602 - jethrogb:sgx-fix-79038, r=Mark-Simulacrum
Fix SGX CI Broken in #79038
This commit is contained in:
commit
6b42900e40
@ -1,6 +1,5 @@
|
|||||||
use std::env::*;
|
use std::env::*;
|
||||||
use std::ffi::{OsStr, OsString};
|
use std::ffi::{OsStr, OsString};
|
||||||
use std::path::PathBuf;
|
|
||||||
|
|
||||||
use rand::distributions::Alphanumeric;
|
use rand::distributions::Alphanumeric;
|
||||||
use rand::{thread_rng, Rng};
|
use rand::{thread_rng, Rng};
|
||||||
@ -92,6 +91,8 @@ fn env_home_dir() {
|
|||||||
|
|
||||||
cfg_if::cfg_if! {
|
cfg_if::cfg_if! {
|
||||||
if #[cfg(unix)] {
|
if #[cfg(unix)] {
|
||||||
|
use std::path::PathBuf;
|
||||||
|
|
||||||
let oldhome = var_to_os_string(var("HOME"));
|
let oldhome = var_to_os_string(var("HOME"));
|
||||||
|
|
||||||
set_var("HOME", "/home/MountainView");
|
set_var("HOME", "/home/MountainView");
|
||||||
@ -109,6 +110,8 @@ fn env_home_dir() {
|
|||||||
|
|
||||||
if let Some(oldhome) = oldhome { set_var("HOME", oldhome); }
|
if let Some(oldhome) = oldhome { set_var("HOME", oldhome); }
|
||||||
} else if #[cfg(windows)] {
|
} else if #[cfg(windows)] {
|
||||||
|
use std::path::PathBuf;
|
||||||
|
|
||||||
let oldhome = var_to_os_string(var("HOME"));
|
let oldhome = var_to_os_string(var("HOME"));
|
||||||
let olduserprofile = var_to_os_string(var("USERPROFILE"));
|
let olduserprofile = var_to_os_string(var("USERPROFILE"));
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user