6 if test "$#" != 1; then
7 printf >&2 'usage: update-test-samples.bash /path/to/PyAV/source\n'
13 exec > "$(dirname "$
(readlink
-f "$0")")/test-samples.toml"
18 prefetch_json
=$
(nix store prefetch-file
--json "${url}")
19 sri_hash
=$
(jq
-r .
hash <<< "${prefetch_json}")
20 printf '"%s" = { url = "%s", hash = "%s" }\n' "${path}" "${url}" "${sri_hash}"
32 "\\b${function}\\([\"']([^\"']+)[\"']\\)" \
36 unique_samples
=$
(sort -u <<< "${samples}")
38 while IFS
= read -r sample
; do
39 fetch
"${base_path}/${sample}" "${base_url}/${sample}"
40 done <<< "${unique_samples}"
43 fetch_all fate_suite fate-suite
"http://fate.ffmpeg.org/fate-suite"
44 fetch_all curated pyav-curated
"https://pyav.org/datasets"