fix: rm newline in version

This commit is contained in:
Aravinth Manivannan 2023-09-06 13:33:34 +05:30
parent 23f4922a18
commit be66de4c8f
Signed by: realaravinth
GPG key ID: AD9F0F08E855ED88

View file

@ -10,7 +10,7 @@ impl Docker {
.expect("unable to obtain Docker version");
let x = String::from_utf8(version.stdout).unwrap();
let x: Vec<&str> = x.split("Docker version ").collect();
x.get(1).unwrap().to_string()
x.get(1).unwrap().trim().to_string()
}
pub fn run_container(name: &str, img: &str) {