In my last post, I talked about program installation in Linux, more specifically, about the concepts that it usually involves (such as packages, package managers and repositories). Now I want to talk about the actual process that I would recommend for installing a certain program into a Linux powered desktop.

I usually think of program installation as a series of options, from more preferable to less preferable. Below, these options are listed in descending order of preference. You’re meant to use the first one, if available. If not, continue with the second one, and so on. These instructions apply to programs that are made available for Linux by their official developers. There are methods for installing non-Linux software, through Wine for example, but these won’t be discussed.

Option 1: Using a Package Manager with a default repository

If you want to install, say, inkscape, the first thing to do is to verify if it is available on your Package Manager, either in a native one (such as apt, dnf or yum, depending on your distro) or in a distribution-independent one (like Flatpak or Snap). To verify availability and install the software, you can use a Package Manager directly (in the terminal), or refer to a graphical “Software Store”, as they’re installed by default on most distributions. It is worth noting that both options will do pretty much the same, since graphical software management tools actually rely on the system’s package manager(s).

GNOME Software. A graphical tool meant to ease the installation of software via package managers

To install software via a terminal window, you can use the corresponding commands:

Package ManagerSearch for a packageInstall a package
apt (Advanced Packaging Tool)apt search [Search term]apt install [Program name]
yum (Yellow dog Updater)yum search [Search term]yum install [Program name]
dnf (DaNdiFied Yum)dnf search [Search term]dnf install [Program name]
zypperzypper se [Search term]zypper in [Program name]
pacmanpacman -F [Search term]pacman -S [Program name]
flatpakflatpak search [Search term]flatpak install [origin] [Program]
Commands for searching and installing packages on most common package managers. Usually, installation commands will require you to use sudo before them.

All Linux systems have one native package manager installed by default, and they may also have a universal one (you can also install one of those for yourself, if you’d like). In some cases, an app may be available in both of them. In such cases, you can install either (it is worth noting that said alternatives aren’t exactly the same app, but different versions of it); Personally, I would install the native package, since they tend to be lighter than their universal counterparts.

This method (using a package manager) is the recommended one, because it is quick, safe (since default repos wouldn’t usually contain malware) and leaves the program updates in charge of the manager (unlike traditional Windows Apps, for example, where each program is responsible for updating itself).

Option 2: Adding a third-party repo

In case that the program you want to install isn’t available through your package manager, you’ll usually head towards its official webpage. If said program is available for Linux, an installation method should be mentioned. Sometimes, the developers will create a third-party repo. After that repo is added to a package manager, you can install the program as mentioned in the previous option, and enjoy the advantages disclosed earlier, such as managed updates.

The Sublime Text developers, for example, actually provide third-party repos for program installation, alongside instructions on how to use them. This process may vary from package manager to package manager, you should check how the process works in the corresponding documentation.

It is worth noting that you must be careful with this option. Please verify that you’re indeed in the official website, and keep an eye for something sketchy. Third party repos may not be entirely safe, since they aren’t verified like the default ones.

Option 3: Install a static version of an App

In case none of the former options are available, you are restricted to installing a static version of an App, with whatever method is made available by its developers. On the official website, the download or install section may contain a file for you to download, containing the app itself. This app won’t be updated through a package manager (and very likely won’t be updated at all, in such case is up to you to download new versions if you need them).

The file for you to download may be:

  • A package such as a .deb file or an .rpm file for your distro. You can install these with a package manager, but they won’t get updates since they aren’t actually in the system repos. These distribution method will usually have different packages for different distros and versions, and a wrong one may not install at all (since it may require distro-specific dependencies).
  • An AppImage, which is a self-contained app in a single file (analog to Windows’ .exe files). These can be run with a simple click, after allowing it to execute as a program (usually you can do that with a right click option on the file explorer).
  • A compressed folder with source code or all the program files, which should also contain instructions on how to install it properly. Usually there is a script which takes care of it.

So these are the standard methods for program installation in Linux, listed in order of preference. Hope this is useful to you and see you next time!

Featured image by X-VARLESH-X, developer of the Papirus Icon Theme.