2 releases

0.1.1 Jul 11, 2022
0.1.0 Sep 19, 2021

#1981 in Development tools

Download history 11/week @ 2024-08-31 3/week @ 2024-09-07 22/week @ 2024-09-14 49/week @ 2024-09-21 32/week @ 2024-09-28 43/week @ 2024-10-05 29/week @ 2024-10-12 28/week @ 2024-10-19 10/week @ 2024-10-26 18/week @ 2024-11-02 5/week @ 2024-11-09 2/week @ 2024-11-16 6/week @ 2024-11-23 22/week @ 2024-11-30 31/week @ 2024-12-07 12/week @ 2024-12-14

71 downloads per month
Used in aim

MIT license

5KB
58 lines

untildify

Utility to replace ~ with user home directory

Example

extern crate untildify;

fn main() {
  println!("Untildify : {}", untildify::untildify("~/Desktop"));
  // prints /Users/<user_name>/Desktop
  
  // Other Examples
  assert_eq!(untildify("~/a/b/c/d/e"), "/User/Untildify/a/b/c/d/e");
  assert_eq!(untildify("~/"), "/User/Untildify/");
}

Dependencies

~2.2–3MB
~54K SLoC