|
|
|
@ -60,10 +60,11 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
match Command::new("hddtemp").output() {
|
|
|
|
|
match Command::new(args.hddtemp_executable.clone()).output() {
|
|
|
|
|
Ok(val) => val,
|
|
|
|
|
Err(e) => {
|
|
|
|
|
println!("Error running hddtemp at all: {}", e.to_string());
|
|
|
|
|
println!("hddtemp = {}", args.hddtemp_executable.clone());
|
|
|
|
|
return Ok(());
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
@ -72,7 +73,7 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
|
|
|
|
|
let mut drive_temps: Vec<String> = vec![];
|
|
|
|
|
|
|
|
|
|
for drive in drives {
|
|
|
|
|
let output = match Command::new("hddtemp").arg(drive.clone()).output() {
|
|
|
|
|
let output = match Command::new(args.hddtemp_executable.clone()).arg(drive.clone()).output() {
|
|
|
|
|
Ok(val) => val,
|
|
|
|
|
Err(e) => {
|
|
|
|
|
println!("Error running hddtemp: {}", e.to_string());
|
|
|
|
@ -154,4 +155,7 @@ struct CliArgs {
|
|
|
|
|
/// Path to config .toml file
|
|
|
|
|
#[arg(short, long)]
|
|
|
|
|
config_file: String,
|
|
|
|
|
|
|
|
|
|
#[arg(short, long)]
|
|
|
|
|
hddtemp_executable: String,
|
|
|
|
|
}
|
|
|
|
|