Skip to main content

logical_path_for_file_input

Function logical_path_for_file_input 

Source
pub fn logical_path_for_file_input(path: &Path, cwd: &Path) -> String
Expand description

Generate a logical path for a file input

If the path is relative, return it as-is with forward slashes. If the path is absolute and within cwd, return the relative portion. Otherwise, return just the filename.