summaryrefslogtreecommitdiff
path: root/src/util/path_display.rs
blob: e9dca4b2af25976e19b52851ebeab16ebe42090d (plain) (blame)
1
2
3
4
5
6
7
8
9
use std::path::Path;

pub fn display_path(path: &Path) -> String {
    let s = format!("{:?}", path);
    s.strip_prefix('"')
        .and_then(|s| s.strip_suffix('"'))
        .unwrap_or(&s)
        .to_string()
}