Nemanja Mikic 8339b9b033 python-build: show download progress in interactive terminals
---
Co-authored-by: Ivan Pozdeev <vano@mail.mipt.ru>
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
2026-09-27 11:00:13 +03:00

45 lines
549 B
Bash
Executable File

#!/usr/bin/env bash
set -euo pipefail
aria2c=
wget=
src=
dest=
dir_=
case "$1" in
aria2c)
aria2c=1;;
wget)
wget=1;;
esac
while (($#)); do
case "$1" in
-o)
if [[ -z $wget ]]; then
dest="$2"
shift
fi
;;
-O)
if [[ -n $wget ]]; then
dest="$2"
shift
fi
;;
-d)
if [[ -n $aria2c ]]; then
dir_="$2/"
shift
fi
;;
-*)
;;
*)
src="$FIXTURE_ROOT/${1##*/}"
;;
esac
shift
done
cp "$src" "${dir_}${dest}"