nodus 0.6.0

Local-first CLI for managing project-scoped agent packages.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use std::borrow::Cow;
use std::path::Path;

use path_slash::PathExt;

pub fn display_path(path: &Path) -> String {
    if path.as_os_str().is_empty() {
        ".".into()
    } else {
        match path.to_slash_lossy() {
            Cow::Borrowed(value) => value.to_string(),
            Cow::Owned(value) => value,
        }
    }
}