use absolute path in symlinks
This commit is contained in:
@@ -138,9 +138,11 @@ fn path_to_lowercase(path: &Path) -> PathBuf {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fn create_symlink_for_file(src: &Path, dst: &Path) -> io::Result<()> {
|
fn create_symlink_for_file(src: &Path, dst: &Path) -> io::Result<()> {
|
||||||
|
let absolute_path = fs::canonicalize(src)?;
|
||||||
|
|
||||||
#[cfg(unix)]
|
#[cfg(unix)]
|
||||||
{
|
{
|
||||||
unix::fs::symlink(src, dst)
|
unix::fs::symlink(absolute_path, dst)
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(windows)]
|
#[cfg(windows)]
|
||||||
|
|||||||
Reference in New Issue
Block a user