multipath

Crates.iomultipath
lib.rsmultipath
version1.0.0
sourcesrc
created_at2020-06-25 17:30:22.759755
updated_at2020-10-07 18:47:11.436666
descriptionA library to split file path, like `/home/{user,admin}/file.txt`.
homepage
repositoryhttps://github.com/Jimskapt/multipath
max_upload_size
id257952
size11,393
Thomas Ramirez (Jimskapt)

documentation

README

multipath   crates_badge doc_badge MIT_badge Cargo tests

A library to split file path, like /home/{user,admin}/file.txt.

⚠ Warning : this version now satisfies all the tests. However, I think the code need to be optimized !

Example :

fn main() {
    assert_eq!(
        multipath::parse("/home/{user,admin}/{Desktop,Download}/file.txt"),
        vec![
            "/home/user/Desktop/file.txt",
            "/home/user/Download/file.txt",
            "/home/admin/Desktop/file.txt",
            "/home/admin/Download/file.txt",
        ]
    );
}

Documentation

Please take a look to :

Commit count: 4

cargo fmt