diff --git a/src/lib.rs b/src/lib.rs index 3fcf0b4..fcb1f05 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -23,7 +23,7 @@ pub fn untildify(input_path: &str) -> String { return match get_host_dir() { Some(path) => { let host_dir = path.to_str().unwrap(); - let re = Regex::new(r"^~([/\w.]+)").unwrap(); + let re = Regex::new(r"^~([/\w.-]+)").unwrap(); match re.captures(input_path) { Some(captures) => { return format!("{}{}", host_dir, &captures[1]);