use-dir 0.0.1

Practical directory path utility primitives
Documentation
  • Coverage
  • 92.31%
    12 out of 13 items documented1 out of 12 items with examples
  • Size
  • Source code size: 11.61 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 372.34 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 8s Average build duration of successful builds.
  • all releases: 8s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • Homepage
  • Documentation
  • RustUse/use-fs
    1 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • CloudBranch

use-dir

Practical directory path utility primitives for RustUse.

Experimental

use-dir is experimental while the use-fs workspace remains below 0.3.0.

Example

use use_dir::{ensure_dir_trailing_separator, path_depth};

assert_eq!(ensure_dir_trailing_separator("docs/guides"), "docs/guides/");
assert_eq!(path_depth("docs/guides/getting-started"), 3);

Scope

  • lexical directory helpers
  • root, current, and parent directory checks
  • trailing-separator normalization
  • directory-oriented prefix and relative-path helpers

Non-goals

  • directory creation or reading
  • directory walking
  • symlink resolution
  • filesystem permission management

License

Licensed under either of the following, at your option:

  • Apache License, Version 2.0
  • MIT license