What the difference bw the ways of installing debs files?

what the difference bw:
1-sudo apt install app
2-download deb file and install it using gdebi or software center, sudo dpkg -i ?

1 Like

For me, convenience and time. With the command you install it directly, with the .deb you have to download and then install it through Software Center. If you prefer saving time you use the terminal, if you prefer using a GUI for convenience you download and install it manually.

1 Like

dpkg is the base command to handle Debian packages, including things like installing, analyzing dependencies, etc. But it cannot resolve unmet dependencies that are missing in your system so it may lead to errors during installation.
You can actually read about a recent example here on the forums of such issue: Failed to install veracrypt

apt will create a dependency list before attempting to install the package and install those dependencies first. It also works the other way around when removing packages by flagging whatever dependencies are no longer being used, although it won't remove them by default, that's what the apt autoremove command is for.

Note that it still uses dpkg for installing packages, you can think of apt as the "frontend" and dpkg the "backend" in terms of how closely they work in regard to the user. So these two tools are usually working together.

4 Likes

I would like to add that if you install through apt using a repository, this will allow that any package upgrades can be handled through the upgrader or terminal command sudo apt upgrade.

If you install a .deb package with dpkg or gdebi, you often will need to independently manually upgrade that package if an upgrade is released by the developer.

4 Likes

1==dpkg or gdebi will get dependencies if needed automatically as apt do?
2==there is different bw if the app is listed or offered in software center as apt vs if the app is installed by .deb file i used software center to install it?

I'm having right this problem with my Discord .deb, I understood that to update it excluding any other available update I must enter its update command on the terminal despite I installed the version 0.0.28 as I thought to just extract it where the actual version is :grin:.

I am not sure if this is because I use BetterDiscord or not... But if updates are available for Discord when I launch it, it gives a popup window notifying me I need to upgrade it.
It... pretty much forces me to download and install the latest .deb package, whether I want to or not. It will not run Discord until I do.

I find it very invasive and annoying.

1 Like

Yeah, I know, as I said on another post I hate this stubbornness for proposing to install the latest updates, every time you run Discord it stops some seconds for that hell of updates check, that in my case gives a non-indifferent delay on launching DIscord effectively (I mean, the main screen, that's it). Then I never faced the .deb update matter till now, but I'll just enter the update command and see what happens.

:point_up:

Depends on how the Software Store is implemented, or even how the package itself is implemented. For example I installed Steam using the .deb package and let the Software Store handle it, and it did create an entry for apt to keep it up to date.

2 Likes

Well, I'd have liked the same for the original Discord .deb :face_exhaling:.

How about Synaptic (GUI for APT)? (That's what I tend to use, I'm a sucker for GUIs.)

By default, does it handle things exactly the same as the apt install command? How does it handle uninstalling? E.g. does it autoremove unused dependencies?

Yes.
With Synaptic, you must select "Remove Completely" in order to get the same effect as sudo apt remove --purge ...
Synaptic handles only apt - and it does it with the same methods as all the terminal commands. It is just a frontend GUI that does the commands for you.
But if you click the Apply button, then in the popover window, Click the Details button during the upgrading or installing process, you will see all the same things you would have seen in terminal had you used the apt commands.

1 Like

i downloaded deb file for anydesk app and deb file for iruinwebcam app, and i opened it with software center to install them.after that, for anydesk it didn't list on software center, and for iruinwebcam it listed on software center, but for both i notice they are not available to be updated

Thanks!