mirror of
https://github.com/Grasscutters/Cultivation.git
synced 2025-12-13 23:54:48 +01:00
fix: remove duct
This commit is contained in:
@@ -157,7 +157,7 @@ fn main() -> Result<(), ArgsError> {
|
||||
println!("You running as a non-elevated user. Some stuff will almost definitely not work.");
|
||||
println!("===============================================================================");
|
||||
|
||||
reopen_as_admin();
|
||||
//reopen_as_admin();
|
||||
}
|
||||
|
||||
// Setup datadir/cultivation just in case something went funky and it wasn't made
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
use duct::cmd;
|
||||
use ini::Ini;
|
||||
use std::ffi::OsStr;
|
||||
use std::path::PathBuf;
|
||||
use std::process::Command;
|
||||
|
||||
#[cfg(windows)]
|
||||
use {
|
||||
@@ -60,7 +60,10 @@ pub fn run_command(program: &str, args: Vec<&str>, relative: Option<bool>) {
|
||||
std::env::set_current_dir(&path_buf).unwrap();
|
||||
}
|
||||
|
||||
cmd(prog, args).run().unwrap();
|
||||
// Run the command
|
||||
let mut command = Command::new(&prog);
|
||||
command.args(&args);
|
||||
command.spawn().unwrap();
|
||||
|
||||
// Restore the original working directory
|
||||
std::env::set_current_dir(cwd).unwrap();
|
||||
|
||||
Reference in New Issue
Block a user