Function iroh_blobs::util::fs::canonicalized_path_to_string
source · pub fn canonicalized_path_to_string(
path: impl AsRef<Path>,
must_be_relative: bool
) -> Result<String>
Expand description
This function converts an already canonicalized path to a string.
If must_be_relative
is true, the function will fail if any component of the path is
Component::RootDir
This function will also fail if the path is non canonical, i.e. contains
..
or .
, or if the path components contain any windows or unix path
separators.