mirror of
https://git.jami.net/savoirfairelinux/jami-client-qt.git
synced 2025-08-06 15:55:48 +02:00

Set minimum macOS version for sparkle updater to 10.14. The same minimum version is required by qt 6. So only users with macOS 10.14 or higher will be offered to update jami to qt version on macOS. Change-Id: I58b081a2a042db118d06724f7a6e9359feefb59c
46 lines
1.5 KiB
Bash
Executable file
46 lines
1.5 KiB
Bash
Executable file
#!/bin/bash
|
|
|
|
# Take the package to add as argument ./sparkle-xml-updater.sh jami.dmg
|
|
|
|
REPO_FOLDER=$1
|
|
SPARKLE_FILE=$2
|
|
REPO_URL=$3
|
|
PACKAGE=$4
|
|
DSA_KEY=$5
|
|
CHANNEL_NAME=$6
|
|
VERSION=$7
|
|
BUILD=$8
|
|
|
|
if [ ! -f ${PACKAGE} -o ! -f ${DSA_KEY} ]; then
|
|
echo "Can't find package or dsa key, aborting..."
|
|
exit 1
|
|
fi
|
|
|
|
if [ -f ${REPO_FOLDER}/${SPARKLE_FILE} ]; then
|
|
ITEMS=$(sed -n "/<item>/,/<\/item>/p" ${REPO_FOLDER}/${SPARKLE_FILE})
|
|
fi
|
|
|
|
PACKAGE_SIZE=`stat -f%z ${PACKAGE}`
|
|
DATE_RFC2822=`date "+%a, %d %b %Y %T %z"`
|
|
|
|
cat << EOFILE > ${REPO_FOLDER}/${SPARKLE_FILE}
|
|
<?xml version="1.0" encoding="utf-8"?>
|
|
<rss version="2.0" xmlns:sparkle="http://www.andymatuschak.org/xml-namespaces/sparkle" xmlns:dc="http://purl.org/dc/elements/1.1/">
|
|
<channel>
|
|
<title>${CHANNEL_NAME}</title>
|
|
<link>${REPO_URL}/${SPARKLE_FILE}</link>
|
|
<description>Most recent changes with links to updates.</description>
|
|
<language>en</language>
|
|
<item>
|
|
<title>"${CHANNEL_NAME}-${BUILD}"</title>
|
|
<pubDate>$DATE_RFC2822</pubDate>
|
|
<sparkle:version>${BUILD}</sparkle:version>
|
|
<sparkle:shortVersionString>${VERSION}</sparkle:shortVersionString>
|
|
<sparkle:minimumSystemVersion>10.14.0</sparkle:minimumSystemVersion>
|
|
<enclosure url="${REPO_URL}/$(basename ${PACKAGE})" length="$PACKAGE_SIZE" type="application/octet-stream" sparkle:dsaSignature="$(./sign_update.sh ${PACKAGE} ${DSA_KEY})" />
|
|
</item>
|
|
$(echo -e "${ITEMS}")
|
|
</channel>
|
|
</rss>
|
|
EOFILE
|
|
|