diff options
Diffstat (limited to 'src/info.rs')
-rw-r--r-- | src/info.rs | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/src/info.rs b/src/info.rs index 3ff2576..5653326 100644 --- a/src/info.rs +++ b/src/info.rs @@ -1,13 +1,3 @@ -pub fn pwd() -> anyhow::Result<String> { - let mut pwd = std::env::current_dir()?.display().to_string(); - if let Ok(home) = std::env::var("HOME") { - if pwd.starts_with(&home) { - pwd.replace_range(..home.len(), "~"); - } - } - Ok(pwd) -} - pub fn user() -> anyhow::Result<String> { Ok(users::get_current_username() .ok_or_else(|| anyhow::anyhow!("couldn't get username"))? |