DESCRIPTION="Telegram client from the official site"
DESCRIPTION="Telegram client from the official site"
PRODUCTALT="stable beta"
TIPS="Run 'epm play telegram-desktop beta' to install beta version of the Telegram client. Run 'epm play telegram-desktop version' to install the version of the Telegram client."
if["$1"="--remove"];then
BRANCH="[0-9]"
# $PKGNAME-stable really
if echo"$2" | grep-q"beta"|| epm installed Telegram-beta ;then
epm remove $(epmqp $PKGNAME)
BRANCH=beta
exit
PKGNAME=$PKGNAME-$BRANCH
fi
fi
VERSION=".*$BRANCH"
[-n"$2"]&&["$2"!="beta"]&&VERSION="$2"
.$(dirname$0)/common.sh
.$(dirname$0)/common.sh
PKGURL=$(epm tool eget --list--latest https://github.com/telegramdesktop/tdesktop/releases "tsetup.*.tar.xz")#"
PKGURL=$(epm tool eget --list--latest https://github.com/telegramdesktop/tdesktop/releases "tsetup.$VERSION.tar.xz")#"