Hacker News new | ask | show | jobs
by kaliszad 1021 days ago
From the thread it seems you are on Ubuntu. There are basically two package managers out of the box. One, the traditional combo of dpkg + apt on top is deeply embedded into the system. You can install a Discord .deb package using `$ sudo dpkg -i ~/Downlaods/discord-0.0.28.deb` or whatever because it is not in the operating system's repositories. If it was, it would be `$ sudo apt install discord` or something along those lines.

The Snap packaging system also includes a layer of software that can sandbox the packages it installed. The idea is, a single package is less distro-specific and also is limited in the damage it can do. Ubuntu is the main user of Snap. Many other distributions, especially Fedora and the like seem to lean more towards Flatpak, which is a different take on what Snap does. Yes, it is complicated but the idea is to increase the security and portability of software packages for Linux. To manage Snap packages from the command line, you can use the snap command.

1 comments

Yeah, I think I may have got the second installation working via the sudo dpkg route, but I'm not sure. I know I definitely tried it as part of troubleshooting the issue. If that is what I did to eventually get Discord working again, then it's strange that I now have two installations, because the download of the .deb file is what the Discord client wanted me to do in the first place.

That being said, I probably initially installed it via Snap--but then, shouldn't it have auto-updated? Yet the Snap store version is still stuck on v 0.28, and the Discord client is what insisted I download the .deb for 0.29. :shrug:

I do not think either of the above routes is too onerous or complicated, but I think the situation is made more complicated by the multiple options. If I am understanding things correctly, APT is a third option in addition to Snap and downloading .deb directly--actually, there is a fourth, which is a variety of things we can lump together under "execute an an installation script"

Apt is the default thing that manages dpkg for you, does dependency resolution, etc. dpkg is quite low level actually. Snap and Flatpak and others are en vogue now, they are basically more app-storey approach to application installation, permissions and more. So apt/ dpkg or if you are on Fedora dnf/yum/rpm are the traditional approaches and Snap/ Flatpak is a very different approach altogether.

I would probably just deinstall the Discord from Snap and keep using the .deb/ dpkg approach.