ZaStoGram_desktop/Telegram/build/release.sh
loop-uh 5bce8c10e5 Merge upstream dev through a1ea1ddd8c (7.2.9)
Keeps the ZaStoGram MTProto layout and its unaligned-access fixes, the
Forgejo update checker and the rich-page layout contract; takes the
upstream IV editor edge restore, horizontal overflow width, round video
seek, tlottie renderer and the lib_ui text shaper.
2026-09-23 16:21:17 +03:00

48 lines
1.1 KiB
Shell

set -e
FullExecPath=$PWD
pushd `dirname $0` > /dev/null
FullScriptPath=`pwd`
popd > /dev/null
Param1="$1"
Param2="$2"
Param3="$3"
Param4="$4"
if [ ! -d "$FullScriptPath/../../../DesktopPrivate" ]; then
echo ""
echo "This script is for building the production version of Telegram Desktop."
echo ""
echo "For building custom versions please visit the build instructions page at:"
echo "https://github.com/telegramdesktop/tdesktop/#build-instructions"
exit
fi
Error () {
cd $FullExecPath
echo "$1"
exit 1
}
while IFS='' read -r line || [[ -n "$line" ]]; do
set $line
eval $1="$2"
done < "$FullScriptPath/version"
if [ "$AppVersion" -lt 7002000 ]; then
Error "The v2 update format requires version 7.2 or newer."
fi
VersionForPacker="$AppVersion"
if [ "$AlphaVersion" != "0" ]; then
Error "No releases for closed alpha versions"
elif [ "$BetaChannel" == "0" ]; then
AppVersionStrFull="$AppVersionStr"
AlphaBetaParam=''
else
AppVersionStrFull="$AppVersionStr.beta"
AlphaBetaParam='-beta'
fi
cd "$FullScriptPath"
python3 release.py $AppVersionStr $Param1 $Param2 $Param3 $Param4