summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2015-04-28 14:03:54 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2015-04-28 14:09:11 +0000
commit25a56f81a250cc326f39c73fd87376572333b1ac (patch)
treebb68e620c41e0cac4088422954eb27660ab91b7d
parent553762ca3095fff20e2cd96593ba2d53b6932a36 (diff)
downloadabuild-25a56f81a250cc326f39c73fd87376572333b1ac.tar.bz2
abuild-25a56f81a250cc326f39c73fd87376572333b1ac.tar.xz
abuild: check that source package is not a version number only
github tarballs are normally only a version number. we need to force that those are renamed so we dont get source tarball name collisions.
-rw-r--r--abuild.in10
1 files changed, 10 insertions, 0 deletions
diff --git a/abuild.in b/abuild.in
index 300b4d8..6910de7 100644
--- a/abuild.in
+++ b/abuild.in
@@ -179,6 +179,16 @@ default_sanitycheck() {
esac
list_has ${i##*/} $md5sums $sha256sums $sha512sums \
|| die "${i##*/} is missing in checksums"
+
+ # verify that our source does not have git tag version
+ # name as tarball (typicallly github)
+ if is_remote "$i" && [ "${i#*::}" = "$i" ]; then
+ case ${i##*/} in
+ v$pkgver.tar.*|$pkgver.tar.*)
+ die "source ${i##*/} needs to be renamed to avoid possible collisions"
+ ;;
+ esac
+ fi
done
fi