11

I installed Telegram by visiting https://desktop.telegram.org/ and downloaded a tar.xz file. After which I ran

tar -xJf telegram.tar.xz

which uncompressed the tar.xz file and gave me Telegram and Updater in a folder.

Both the files have an executable (application/x-executable) as their type. I installed Telegram by double clicking the Telegram file.

Now, I'm not sure how do I uninstall it. I tried

apt remove telegram

but it said "Unable to locate package telegram" since it wasn't installed from apt. How do I properly uninstall Telegram Desktop?

3 Answers 3

13

This Telegram app just installs a .desktop file, its icon and a folder where it saves its data:

Remove the folder with the Telegram and Updater file.

Then run:

rm -Rf \
  ~/.local/share/icons/telegram.png \ 
  ~/.local/share/applications/telegramdesktop.desktop \
  ~/.local/share/TelegramDesktop
7

I installed Telegram by double clicking the Telegram file.

No, you didn't install Telegram by double clicking, neither apt was involved in any way. The tar.xz package contains a pre-compiled executable for Telegram Desktop and it executes it every time you launch it. Simply delete the extracted folder to get rid of Telegram.


Also follow the answer by @pLumo to remove other residue files.

2
  • I have managed to remove the telegram from @ pLumo's solution. But I get some idea of what actually happened when I double clicked on the Telegram from your answer. I would like to know more about what exactly happened under the hood. Do you know any relevant article that you can point me to? Thanks Oct 22, 2019 at 6:59
  • You can check the official GitHub repo: github.com/telegramdesktop/tdesktop
    – pomsky
    Oct 22, 2019 at 7:19
1

I think the way you did it, Telegram is not really "installed" anywhere other than where you unpacked the telgram.tar.xz file. It runs directly from that location. When you unpacked it you got a Telegram directory, right? Just remove that, then Telegram is gone.

The apt remove way of removing packages generally works when that package was installed using apt install.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .