Use relative paths for --find-links and local registries (#6566)

## Summary

See: https://github.com/astral-sh/uv/issues/6458
This commit is contained in:
Charlie Marsh 2024-08-24 22:41:47 -04:00 committed by GitHub
parent 3902bb498d
commit 7fa265a11b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
18 changed files with 834 additions and 264 deletions

View file

@ -270,6 +270,9 @@ pub fn canonicalize_executable(path: impl AsRef<Path>) -> std::io::Result<PathBu
/// `lib/python/site-packages/foo/__init__.py` and `lib/python/site-packages` -> `foo/__init__.py`
/// `lib/marker.txt` and `lib/python/site-packages` -> `../../marker.txt`
/// `bin/foo_launcher` and `lib/python/site-packages` -> `../../../bin/foo_launcher`
///
/// Returns `Err` if there is no relative path between `path` and `base` (for example, if the paths
/// are on different drives on Windows).
pub fn relative_to(
path: impl AsRef<Path>,
base: impl AsRef<Path>,