Some(_)=>err_unrec(format!("Something has gone terribly wrong")),
Some(1)=>err_unrec(format!("Package {} not found in repository {}",pkg.split("/").collect::<Vec<&str>>()[1],pkg.split("/").collect::<Vec<&str>>()[0])),
None=>err_unrec(format!("Process terminated")),
Some(_)=>err_unrec(format!("Something has gone terribly wrong")),
None=>err_unrec(format!("Process terminated")),
}
}
}
}
}
}
None=>{
false=>{
letout=Command::new("pacman")
letcaps=re.captures(&pkg);
.arg("-Ss")
matchcaps{
.arg(format!("^{}$",&pkg))
Some(_)=>{
.stdout(Stdio::null())
letout=Command::new("pacman")
.status()
.arg("-Ss")
.expect("Something has gone wrong.");
.arg(format!(
matchout.code(){
"^{}$",
Some(0)=>repo.push(pkg),
caps.unwrap().get(1).map_or("",|m|m.as_str())
Some(1)=>aur.push(pkg),
))
Some(_)=>err_unrec(format!("Something has gone terribly wrong")),