diff --git a/res/welcome.txt b/res/welcome.txt index 18f8a72..b9b1974 100644 --- a/res/welcome.txt +++ b/res/welcome.txt @@ -1,4 +1,4 @@ -ashe@tilde.club's password: +ashe@tilde.club's password: Welcome to AsheOS 21.12.1 LTS (HRT/Estrix 6.25.21-wasm) * Technical: https://tempest.dev diff --git a/src/path.rs b/src/path.rs index e09743a..54c2436 100644 --- a/src/path.rs +++ b/src/path.rs @@ -1,8 +1,14 @@ use std::str::FromStr; pub fn join(root : &str, path : &str) -> String { + let mut path = String::from_str(path).unwrap(); + + if path.starts_with("~") { + path = path.replace("~", "/home/ashe"); + } + if path.starts_with("/") { - return String::from_str(path).unwrap() + return path } let mut result_segments : Vec<&str> = root.split("/").filter(|s| !s.is_empty()).collect();