what i mean is those installer files that can also contain a pre and postinstall script. So not talking about regular package managers. I tried searching on google but I couldn't find it. Sorry if i am being an idiot. I heard something about appimages, is that the same or not? personally I am looking to switch to arch from macos but i like the installers.
-
Ah well okay but that is not what i am looking for. I was looking for a file that installs its contents and stuff without running commands– martijnt500Commented May 12, 2021 at 11:38
-
Ah well I guess that my question is a little useless then. Those pkg files are clearly not needed.– martijnt500Commented May 12, 2021 at 11:41
-
I wouldn’t say it’s useless, you didn’t know the answer which is fine. I wasn’t sure about what you were looking for exactly, otherwise I’d have written a proper answer instead of comments; I can still do that if you want. You might find Is there .sh installer (software archive is append to .sh flat text file) generating tools for unix? interesting too.– Stephen KittCommented May 12, 2021 at 11:44
-
Do you know what a .pkg file is?– martijnt500Commented May 12, 2021 at 12:06
-
Maybe that helps for a proper answer?– martijnt500Commented May 12, 2021 at 12:06
1 Answer
In most cases, the recommended way to install applications on Linux distributions is to go through the package manager; this brings a number of benefits, including the ability to install any required dependencies, the availability of security updates, and the authentication of packages (see How is the authenticity of Debian packages guaranteed? for Debian; many other distributions have similar setups). Such packages can include pre- and post-installation scripts if necessary.
Installing applications from the package manager doesn’t have to involve commands; many desktop environments integrate the package manager into their “software catalogs”. GNOME for example has its Software application (which also integrates Flatpak, see below).
However it is possible to install applications in a manner similar to what you’re used to on macOS with .pkg
files. In many desktop environments nowadays, double-clicking on a package file will install it, prompting for administrative authorisation as necessary. In many environments this skips the authentication side of packages though, but packages installed in this manner will also be upgradeable if upgrades are available in the system’s configured repositories.
It is also possible to create .pkg
-style installers for Linux, e.g. using MojoSetup (see Making Download & Install Style Programs for Linux). Programs can also be packaged using Flatpak or similar tools; in Flatpak’s case, the result will typically be a .flatpakref
file which can be installed by double-clicking too (this is how installation from Flathub works).
AppImage files are slightly different; they are self-contained applications in a single file that don’t require installation. All that’s needed is to download them, and then double-clicking on them will run the packaged program, without any installation step (and thus no need for administrative access).
-
Thank you for the answer. I will look into the different approaches you have given. (BTW how to mark an answer as the correct one?) EDIT: I found the check mark. Commented May 12, 2021 at 18:08