catalyst-auto: update arch configs after timestamp changes
Commit ed258c751b
(change
datestamp->timestamp) broke a lot of builders. The symlinks
and upload logic were all based on the datestamp. Update it
to use the new timestamp format.
This commit is contained in:
parent
bbca329576
commit
40ed3e84d7
8 changed files with 179 additions and 107 deletions
|
@ -24,17 +24,26 @@ give_latest_from_dates() {
|
|||
tr '~' '-'
|
||||
}
|
||||
|
||||
# Replace the date/time stamp in the filename to "latest".
|
||||
# Forms we handle:
|
||||
# stage3-xxx-2018.0.tar.bz2
|
||||
# stage3-xxx-20180116.tar.bz2
|
||||
# stage3-xxx-20180116T015819Z.tar.bz2
|
||||
convert_filename() {
|
||||
sed -E 's:-20[0-9]+(\.[0-9]+|T[0-9]+Z)?:-latest:g'
|
||||
}
|
||||
|
||||
update_symlinks() {
|
||||
# Symlink the latest stages3 to build from
|
||||
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
||||
pushd $d >/dev/null
|
||||
for f in $(ls stage3-ppc-*bz2 | grep -v latest | give_latest_from_dates ) ; do
|
||||
of=${f/20[0-9][0-9].[0-9]/latest} # for 20XX.Y stuff
|
||||
of=${of/20[0-9][0-9][0-1][0-9][0-9][0-9]/latest} # for $
|
||||
ln -sf $f $of
|
||||
done
|
||||
popd >/dev/null
|
||||
done
|
||||
# Symlink the latest stages3 to build from
|
||||
local d f
|
||||
for d in "${BUILD_SRCDIR_BASE}/builds/default" ; do
|
||||
pushd "${d}" >/dev/null
|
||||
for f in $(ls stage3-ppc-*bz2 | grep -v latest | give_latest_from_dates) ; do
|
||||
local of=$(echo "${f}" | convert_filename)
|
||||
ln -sf "${f}" "${of}"
|
||||
done
|
||||
popd >/dev/null
|
||||
done
|
||||
}
|
||||
|
||||
upload() {
|
||||
|
@ -48,7 +57,7 @@ post_build() {
|
|||
|
||||
case ${spec} in
|
||||
stage3.spec)
|
||||
upload stage3-ppc-*${DATESTAMP}*.bz2*
|
||||
upload stage3-ppc-*${TIMESTAMP}*.bz2*
|
||||
;;
|
||||
esac
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue