catalyst-auto: Combine common functions
Signed-off-by: Matt Turner <mattst88@gentoo.org>
This commit is contained in:
parent
41cdecd812
commit
492aacba77
|
@ -165,6 +165,25 @@ parse_args() {
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
|
give_latest_from_dates() {
|
||||||
|
sed 's,-20,~20,g' | \
|
||||||
|
sort -k +1 -n -t '~' |\
|
||||||
|
awk -F\~ \
|
||||||
|
'BEGIN{i=$1; o=$0};
|
||||||
|
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
||||||
|
END { print o; };' | \
|
||||||
|
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'
|
||||||
|
}
|
||||||
|
|
||||||
# Let's get our own namespaces/etc... to avoid leaking crap.
|
# Let's get our own namespaces/etc... to avoid leaking crap.
|
||||||
containerize() {
|
containerize() {
|
||||||
# If we've already relaunched, nothing to do.
|
# If we've already relaunched, nothing to do.
|
||||||
|
|
|
@ -17,25 +17,6 @@ SET_default_SPECS="stage1.spec stage3.spec"
|
||||||
SET_default_OPTIONAL_SPECS="installcd-stage1.spec installcd-stage2-minimal.spec"
|
SET_default_OPTIONAL_SPECS="installcd-stage1.spec installcd-stage2-minimal.spec"
|
||||||
|
|
||||||
KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/alpha
|
KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/alpha
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
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() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
|
|
|
@ -40,16 +40,6 @@ KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/${ARCH}
|
||||||
|
|
||||||
EXTENSIONS="[.tar.xz,.tar.bz2,.tar.gz,.tar,.sfs]"
|
EXTENSIONS="[.tar.xz,.tar.bz2,.tar.gz,.tar,.sfs]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' | \
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
for d in ${BUILD_SRCDIR_BASE}/{default,hardened} ; do
|
for d in ${BUILD_SRCDIR_BASE}/{default,hardened} ; do
|
||||||
|
|
|
@ -41,16 +41,6 @@ KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/${ARCH}
|
||||||
|
|
||||||
EXTENSIONS="[.tar.xz,.tar.bz2,.tar.gz,.tar,.sfs]"
|
EXTENSIONS="[.tar.xz,.tar.bz2,.tar.gz,.tar,.sfs]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' | \
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
for d in ${BUILD_SRCDIR_BASE}/{default,hardened} ; do
|
for d in ${BUILD_SRCDIR_BASE}/{default,hardened} ; do
|
||||||
|
|
|
@ -15,25 +15,6 @@ SET_default_SPECS="stage1.spec stage2.spec stage3.spec"
|
||||||
|
|
||||||
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
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() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
local d f
|
local d f
|
||||||
|
|
|
@ -15,17 +15,6 @@ SET_default_SPECS="stage1.spec stage2.spec stage3.spec"
|
||||||
|
|
||||||
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
||||||
|
|
|
@ -15,17 +15,6 @@ SET_default_SPECS="stage1.spec stage2.spec stage3.spec"
|
||||||
|
|
||||||
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
||||||
|
|
|
@ -15,17 +15,6 @@ SET_default_SPECS="stage1.spec stage2.spec stage3.spec"
|
||||||
|
|
||||||
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
||||||
|
|
|
@ -15,17 +15,6 @@ SET_default_SPECS="stage1.spec stage2.spec stage3.spec"
|
||||||
|
|
||||||
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
||||||
|
|
|
@ -15,17 +15,6 @@ SET_default_SPECS="stage1.spec stage2.spec stage3.spec"
|
||||||
|
|
||||||
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
||||||
|
|
|
@ -15,17 +15,6 @@ SET_default_SPECS="stage1.spec stage2.spec stage3.spec"
|
||||||
|
|
||||||
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
EMAIL_SUBJECT_PREPEND="[${SUBARCH}-auto]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
for d in ${BUILD_SRCDIR_BASE}/builds/default ; do
|
||||||
|
|
|
@ -17,25 +17,6 @@ KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/hppa
|
||||||
|
|
||||||
EMAIL_SUBJECT_PREPEND="[hppa-auto]"
|
EMAIL_SUBJECT_PREPEND="[hppa-auto]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
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() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
local d f t
|
local d f t
|
||||||
|
|
|
@ -12,25 +12,6 @@ OPTIONAL_SPECS="installcd-stage1.spec installcd-stage2-minimal.spec"
|
||||||
|
|
||||||
KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/ia64
|
KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/ia64
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
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() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
local d f
|
local d f
|
||||||
|
|
|
@ -13,25 +13,6 @@ OPTIONAL_SPECS="ppc32/installcd-stage1.spec ppc32/installcd-stage2-minimal.spec"
|
||||||
KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/powerpc
|
KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/powerpc
|
||||||
|
|
||||||
EMAIL_SUBJECT_PREPEND="[ppc-auto]"
|
EMAIL_SUBJECT_PREPEND="[ppc-auto]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
# Replace the date/time stamp in the filename to "latest".
|
|
||||||
# Forms we handle:
|
|
||||||
# stage3-xxx-2018.0.tar.xz
|
|
||||||
# stage3-xxx-20180116.tar.xz
|
|
||||||
# stage3-xxx-20180116T015819Z.tar.xz
|
|
||||||
convert_filename() {
|
|
||||||
sed -E 's:-20[0-9]+(\.[0-9]+|T[0-9]+Z)?:-latest:g'
|
|
||||||
}
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
|
|
|
@ -14,25 +14,6 @@ SPECS="stage1.spec stage3.spec"
|
||||||
KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/powerpc
|
KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/powerpc
|
||||||
|
|
||||||
EMAIL_SUBJECT_PREPEND="[ppc64le-auto]"
|
EMAIL_SUBJECT_PREPEND="[ppc64le-auto]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
# Replace the date/time stamp in the filename to "latest".
|
|
||||||
# Forms we handle:
|
|
||||||
# stage3-xxx-2018.0.tar.xz
|
|
||||||
# stage3-xxx-20180116.tar.xz
|
|
||||||
# stage3-xxx-20180116T015819Z.tar.xz
|
|
||||||
convert_filename() {
|
|
||||||
sed -E 's:-20[0-9]+(\.[0-9]+|T[0-9]+Z)?:-latest:g'
|
|
||||||
}
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
|
|
|
@ -12,25 +12,6 @@ SET_netboot_SPECS="netboot/netboot.spec"
|
||||||
|
|
||||||
KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/s390
|
KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/s390
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
# Replace the date/time stamp in the filename to "latest".
|
|
||||||
# Forms we handle:
|
|
||||||
# stage3-xxx-2018.0.tar.xz
|
|
||||||
# stage3-xxx-20180116.tar.xz
|
|
||||||
# stage3-xxx-20180116T015819Z.tar.xz
|
|
||||||
convert_filename() {
|
|
||||||
sed -E 's:-20[0-9]+(\.[0-9]+|T[0-9]+Z)?:-latest:g'
|
|
||||||
}
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
local d f
|
local d f
|
||||||
|
|
|
@ -12,25 +12,6 @@ SET_netboot_SPECS="netboot/netboot.spec"
|
||||||
|
|
||||||
KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/s390
|
KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/s390
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
# Replace the date/time stamp in the filename to "latest".
|
|
||||||
# Forms we handle:
|
|
||||||
# stage3-xxx-2018.0.tar.xz
|
|
||||||
# stage3-xxx-20180116.tar.xz
|
|
||||||
# stage3-xxx-20180116T015819Z.tar.xz
|
|
||||||
convert_filename() {
|
|
||||||
sed -E 's:-20[0-9]+(\.[0-9]+|T[0-9]+Z)?:-latest:g'
|
|
||||||
}
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
local d f
|
local d f
|
||||||
|
|
|
@ -10,25 +10,6 @@ KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/sparc
|
||||||
|
|
||||||
EMAIL_SUBJECT_PREPEND="[sparc-auto]"
|
EMAIL_SUBJECT_PREPEND="[sparc-auto]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
# Replace the date/time stamp in the filename to "latest".
|
|
||||||
# Forms we handle:
|
|
||||||
# stage3-xxx-2018.0.tar.xz
|
|
||||||
# stage3-xxx-20180116.tar.xz
|
|
||||||
# stage3-xxx-20180116T015819Z.tar.xz
|
|
||||||
convert_filename() {
|
|
||||||
sed -E 's:-20[0-9]+(\.[0-9]+|T[0-9]+Z)?:-latest:g'
|
|
||||||
}
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
local d f
|
local d f
|
||||||
|
|
|
@ -27,16 +27,6 @@ KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/${ARCH}
|
||||||
|
|
||||||
EXTENSIONS="[.tar.xz,.tar.bz2,.tar.gz,.tar,.sfs]"
|
EXTENSIONS="[.tar.xz,.tar.bz2,.tar.gz,.tar,.sfs]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
for d in ${BUILD_SRCDIR_BASE}/{default,hardened} ; do
|
for d in ${BUILD_SRCDIR_BASE}/{default,hardened} ; do
|
||||||
|
|
|
@ -27,16 +27,6 @@ KCONFIG_DIR=${REPO_DIR}/releases/weekly/kconfig/${ARCH}
|
||||||
|
|
||||||
EXTENSIONS="[.tar.xz,.tar.bz2,.tar.gz,.tar,.sfs]"
|
EXTENSIONS="[.tar.xz,.tar.bz2,.tar.gz,.tar,.sfs]"
|
||||||
|
|
||||||
give_latest_from_dates() {
|
|
||||||
sed 's,-20,~20,g' | \
|
|
||||||
sort -k +1 -n -t '~' |\
|
|
||||||
awk -F\~ \
|
|
||||||
'BEGIN{i=$1; o=$0};
|
|
||||||
{ if($1 != i && i != "") { print o; }; i=$1; o=$0; }
|
|
||||||
END { print o; };' | \
|
|
||||||
tr '~' '-'
|
|
||||||
}
|
|
||||||
|
|
||||||
update_symlinks() {
|
update_symlinks() {
|
||||||
# Symlink the latest stages3 to build from
|
# Symlink the latest stages3 to build from
|
||||||
for d in ${BUILD_SRCDIR_BASE}/{default,hardened} ; do
|
for d in ${BUILD_SRCDIR_BASE}/{default,hardened} ; do
|
||||||
|
|
Loading…
Reference in a new issue