Skip to content

Commit

Permalink
fix: fix --topics download dir
Browse files Browse the repository at this point in the history
  • Loading branch information
eatradish committed Jul 23, 2024
1 parent 8370c22 commit 8904442
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/network.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,10 @@ pub fn fetch_manifests(
combined
.par_iter()
.try_for_each(move |(arch, comp)| -> Result<()> {
let url = format!("{}/dists/{}/{}/binary-{}/Packages", mirror, branch, comp, arch);
let url = format!(
"{}/dists/{}/{}/binary-{}/Packages",
mirror, branch, comp, arch
);
let parsed = Url::parse(&url)?;
let manifest_name = parsed.host_str().unwrap_or_default().to_string() + parsed.path();
let manifest_name = manifest_name.replace('/', "_");
Expand Down Expand Up @@ -114,7 +117,11 @@ pub fn fetch_manifests(
parsed.host_str().unwrap_or_default().to_string() + parsed.path();
let manifest_name = manifest_name.replace('/', "_");

fetch_url(client, &url, &root.join(name))?;
fetch_url(
client,
&url,
&root.join("var/lib/apt/lists").join(manifest_name.clone()),
)?;
manifests_clone_2.lock().unwrap().push(manifest_name);
}
}
Expand Down

0 comments on commit 8904442

Please sign in to comment.