[Git][qa/jenkins.debian.net][master] buildinfos.d.n: fix logic for old buildd files
Holger Levsen (@holger)
gitlab at salsa.debian.org
Mon Jan 20 16:11:38 GMT 2025
Holger Levsen pushed to branch master at Debian QA / jenkins.debian.net
Commits:
554b65a0 by Jochen Sprickerhof at 2025-01-20T17:10:58+01:00
buildinfos.d.n: fix logic for old buildd files
Newer buildinfo files form the buildds are named -buildd.buildinfo and
preferred as fixed in c5bd2cdd5. Before that they where renamed .0 or .1
if the file already existd. This makes sure those are preferred as well.
Signed-off-by: Holger Levsen <holger at layer-acht.org>
- - - - -
1 changed file:
- bin/reproducible_pool_buildinfos.sh
Changes:
=====================================
bin/reproducible_pool_buildinfos.sh
=====================================
@@ -76,10 +76,23 @@ do_day(){
echo "on no $MONTHPATH/$DAY/$FILE does not exist, exiting."
exit 1
elif [ -e $FULLTARGET ] ; then
+ OLD_TARGET="$(readlink -f $FULLTARGET)"
# prefer buildinfo file from the buildd
if [ "${FILE#*-buildd.buildinfo}" != "$FILE" ] ; then
mv $FULLTARGET $FULLTARGET.old
ln -s $MONTHPATH/$DAY/$FILE $FULLTARGET
+ # skip non buildd file if the buildd file was linked already
+ elif [ "${OLD_TARGET#*-buildd.buildinfo}" != "$OLD_TARGET" ]; then
+ :
+ # old buildd files could be named .1 or .0, prefer them in that order.
+ elif [ "${FILE#*.buildinfo.1}" != "$FILE" ]; then
+ mv $FULLTARGET $FULLTARGET.1.old
+ ln -s $MONTHPATH/$DAY/$FILE $FULLTARGET
+ elif [ "${OLD_TARGET#*.buildinfo.1}" != "$OLD_TARGET" ]; then
+ :
+ elif [ "${FILE#*.buildinfo.0}" != "$FILE" ] ; then
+ mv $FULLTARGET $FULLTARGET.0.old
+ ln -s $MONTHPATH/$DAY/$FILE $FULLTARGET
elif [ ! -e "$FULLTARGET.0" ] ; then
ln -s $MONTHPATH/$DAY/$FILE $FULLTARGET.0
echo "$MONTHPATH/$DAY/$FILE linked from $FULLTARGET.0"
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/-/commit/554b65a010fb2b775c3ebe2d126f9245533375a0
--
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/-/commit/554b65a010fb2b775c3ebe2d126f9245533375a0
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/qa-jenkins-scm/attachments/20250120/8c1cbf2f/attachment-0001.htm>
More information about the Qa-jenkins-scm
mailing list