OS: Linux Mint 18.3
I'd describe myself as a low intermediate Linux user.
I just spent about 4 hours working out how to upgrade my version of NodeJS. In the end I had to tweak a build script that was being CURLed.
My question is this: what is the recommended way to approach installing new software or updating existing software in a Linux OS?
In the course of trying to find a solution, for example, I found that it was possible simply to download a .tar.gz for the latest NodeJS version, and then extract... and maybe then configure the PATH env variable. It seems a very simple way to do things.
But somehow this didn't seem to be right: in particular, don't all Linux apps make use of existing packages in your system? So if you are simply using a self-contained set of executables doesn't this mean that you are at risk of duplicating code, and using out-of-date and undocumented dependency modules, etc.?
Also aren't other directories, such as \opt, used by applications when they are installed? I don't know what that's about but it's probably important. Also if you haven't installed using a listed archive you obviously can't just update at the touch of a button (apt-get update
and then apt-get install X
).
Order of priority?
- the first thing (as I understand it) is to look in the local Synaptic repository (if that's the right word). But what to do if what you want isn't there, or as often the case is out-of-date?
- (in Linux Mint) there is also the "Software Manager". I'm never sure how this relates generally to Synaptic.
- after this there are PPAs. Are they in any way inferior or superior to downloading and extracting a compressed file, typically .tar.gz?
- finally, if available, a compressed file.
What are the pros and cons of simple downloaded compressed files compared to using a PPA, when your system's repositories are lacking in up-to-date versions?
For example, error messages I get from apt-get update
seem to indicate that my current MariaDB version is all out of whack: 404 errors from the configured PPA (I presume that's what it is). I seem to need to update or install a new version. Again, there is a .tar.gz for the latest MariaDB which I've just downloaded from the site: it is tempting just to extract that, and tweak the PATH variable as needed.
npm
orpip
or other variations of brawndo-installer (i.e.curl | bash
), you're already breaking your system. See Don't Break Debian - most of it is relevant to Mint and other distros too (whether debian-based or not).