diff --git a/makedist/makedist-announcement.sh b/makedist/makedist-announcement.sh index 26be7df..e7463bb 100755 --- a/makedist/makedist-announcement.sh +++ b/makedist/makedist-announcement.sh @@ -3,14 +3,10 @@ # makedist-announcement.sh - a makedist component which produces announcements # Copyright (c) 2012 by Silvan Calarco # -VERSION=0.1 - -archs=(i586 arm x86_64) +. /usr/share/makedist/VERSION distribution=openmamba -mediumarch=i586 mediumlang=en -signer="Silvan Calarco" siteaddress=www.openmamba.org sitedomain=openmamba.org forumaddress=forum.openmamba.org @@ -178,6 +174,8 @@ function print_pkg_line() { local descr=$1 local searchpkg=$2 + [ "$3" ] && mediumarch=$3 + [ -f "$blocktmpfile" ] || { echo "Error: print_pkg_line: you must call block_start first; skipping." return 1 @@ -232,6 +230,12 @@ if [ ! "${MEDIA_NAME[i]}" ]; then exit 1 fi +# set mediumarch to the first medium architecture for gathering information +for a in ${MEDIA_ARCHS[i]}; do + mediumarch=$a + break +done + mediumplatform=${MEDIA_PLATFORM[i]} mediumsubplatform=${MEDIA_SUBPLATFORM[i]} webmediumdir=pub/$distribution/media/$distversion/$mediumname @@ -335,23 +339,25 @@ if [ ! -e $outputfile -o "$REBUILDANNOUNCEMENT" = "1" ]; then echo "
"$"Language"" | "$"Arch"" | "$"Download link"" | "$"Size"" | "$"Date"" | MD5 |
---|---|---|---|---|---|
" >> $outputfile - case $l in - en) echo -n $"english" >> $outputfile ;; - it) echo -n $"italian" >> $outputfile ;; - es) echo -n $"spanish" >> $outputfile ;; - *) echo -n $"unknown" >> $outputfile ;; - esac - echo " | ${mediumarch} | \ -\ -$distribution-$mediumname-$l-$mediadistversion-$version.${mediumarch}.${medium_suffix} | + echo -n "|||
" >> $outputfile + case $l in + en) echo -n $"english" >> $outputfile ;; + it) echo -n $"italian" >> $outputfile ;; + es) echo -n $"spanish" >> $outputfile ;; + *) echo -n $"unknown" >> $outputfile ;; + esac + echo " | ${a} | \ +\ +$distribution-$mediumname-$l-$mediadistversion-$version.${a}.${medium_suffix} | $mediumsizeMB MB | $mediumdate | $mediummd5 | " >> $outputfile + done done echo -n "
"$"Announcement automatically generated by"" makedist-announcement $VERSION " >> $outputfile
+ echo -n "
"$"Announcement automatically generated by"" makedist $makedist_version " >> $outputfile if [ "$distversion" != "devel" ]; then - echo $"and signed off by"" $signer" >> $outputfile + echo $"and signed off by"" $ANNOUNCEMENTS_SIGNER" >> $outputfile else echo >> $outputfile fi