From dee9611d197ef9db4222f063eac7c3114bb10f73 Mon Sep 17 00:00:00 2001 From: Erich Eckner Date: Thu, 4 Jan 2018 14:08:05 +0100 Subject: bin/build-packages: check if sources are correct before downloading them --- bin/build-packages | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'bin/build-packages') diff --git a/bin/build-packages b/bin/build-packages index bcbec35..ae75b7b 100755 --- a/bin/build-packages +++ b/bin/build-packages @@ -260,6 +260,10 @@ while [ "${count}" -ne 0 ]; do if echo "${straw}" | \ grep -qF ':mirrored_source:'; then # maybe a missing source is/was the problem? + if makepkg --verifysource 2>/dev/null; then + # nope, sources are fine + continue + fi # try to download them from sources.archlinux.org/sources/$repo/$source source_name=$( makepkg --printsrcinfo | \ @@ -292,6 +296,10 @@ while [ "${count}" -ne 0 ]; do if echo "${straw}" | \ grep -qF ':mirrored_source_by_hash:'; then # maybe a missing source is/was the problem? + if makepkg --verifysource 2>/dev/null; then + # nope, sources are fine + continue + fi # download it from sources.archlinux32.org by its hash if ! download_sources_by_hash "${package}" "${repository}" "${git_revision}" "${mod_git_revision}"; then # we can't improve anything, if no source was downloadable -- cgit v1.2.3-70-g09d2