Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions pycargoebuild/fetch.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import typing
from pathlib import Path

from pycargoebuild import __version__
from pycargoebuild.cargo import Crate, FileCrate


Expand Down Expand Up @@ -47,7 +48,10 @@ def fetch_crates_using_aria2(crates: typing.Iterable[Crate], *, distdir: Path
file_list_f.flush()

subprocess.check_call(
["aria2c", "-d", str(distdir), "-i", file_list_f.name],
["aria2c",
"-U", f"pycargoebuild/{__version__} (https://github.com/gentoo/pycargoebuild)",
"-d", str(distdir),
"-i", file_list_f.name],
stdout=sys.stderr)


Expand All @@ -60,7 +64,9 @@ def fetch_files_using_wget(files: typing.Iterable[typing.Tuple[str, Path]]
for url, path in files:
if not path.exists():
subprocess.check_call(
["wget", "-O", str(path), url],
["wget",
"-U", f"pycargoebuild/{__version__} (https://github.com/gentoo/pycargoebuild)",
"-O", str(path), url],
stdout=sys.stderr)


Expand Down
Loading