normalize-path 0.2.1

Like canonicalize, but without performing I/O
Documentation
  • Coverage
  • 100%
    5 out of 5 items documented1 out of 5 items with examples
  • Size
  • Source code size: 14.84 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 178.16 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Links
  • cargo-bins/cargo-binstall
    1999 70 89
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • passcod NobodyXu github:cargo-bins:binstall

Normalizes paths similarly to canonicalize, but without performing I/O.

This is like Python's os.path.normpath.

Initially adapted from Cargo's implementation.

Example

use normalize_path::NormalizePath;
use std::path::Path;

assert_eq!(
    Path::new("/A/foo/../B/./").normalize(),
    Path::new("/A/B")
);