MCPcopy Create free account
hub / github.com/It4innovations/hyperqueue / resolve_path

Function resolve_path

crates/hyperqueue/src/common/placeholders.rs:169–176  ·  view source on GitHub ↗
(map: &PlaceholderMap, path: &Path, base_dir: &Path)

Source from the content-addressed store, hash-verified

167}
168
169fn resolve_path(map: &PlaceholderMap, path: &Path, base_dir: &Path) -> PathBuf {
170 let path: PathBuf = resolve(map, path.to_str().unwrap()).into_owned().into();
171 if !has_placeholders(path.to_str().unwrap()) {
172 normalize_path(&path, base_dir)
173 } else {
174 path
175 }
176}
177
178/// Adds the given base `directory` to the `path`, if it's not already absolute.
179pub fn normalize_path(path: &Path, directory: &Path) -> PathBuf {

Callers 1

resolve_program_pathsFunction · 0.85

Calls 5

resolveFunction · 0.85
has_placeholdersFunction · 0.85
normalize_pathFunction · 0.85
intoMethod · 0.80
to_strMethod · 0.80

Tested by

no test coverage detected