Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Script to install Official Telegram Desktop
MACHINE_TYPE=`uname -m`
# Removing old versions
echo 'Removing old versions'
sudo rm -Rf /opt/telegram*
sudo rm -Rf /usr/bin/telegram
sudo rm -Rf /usr/share/applications/telegram.desktop
echo 'Identify Machine Type'
# Identify Machine Type
if [ ${MACHINE_TYPE} == 'x86_64' ]; then
wget "" -O /tmp/telegram.tar.xz
wget "" -O /tmp/telegram.tar.xz
# Extract the files
echo 'Extracting the files'
sudo tar Jxf /tmp/telegram.tar.xz -C /opt/
sudo mv /opt/Telegram*/ /opt/telegram
# Create a shortcut on system
echo 'Creating symbol link'
sudo ln -sf /opt/telegram/Telegram /usr/bin/telegram
echo 'Installation finish'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment