Perform a single Git fetch when building source distributions (#499)

## Summary

We need to pass in the distribution with the "precise" URL to avoid
refetching.

## Test Plan

Ran `cargo run -p puffin-cli -- pip-compile requirements.in --verbose`
with `flask @ git+https://github.com/pallets/flask.git` and verified
that we only checked out Flask once.
This commit is contained in:
Charlie Marsh 2023-11-25 23:29:41 +00:00 committed by GitHub
parent d54e780843
commit 3eb0a43995
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 54 additions and 77 deletions

View file

@ -128,6 +128,7 @@ impl Fetch {
pub fn path(&self) -> &Path {
&self.path
}
pub fn into_git(self) -> GitUrl {
self.git
}