this post was submitted on 18 Feb 2024
128 points (93.8% liked)

Linux

47744 readers
743 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

Distro agnostic packages like flatpaks and appimages have become extremely popular over the past few years, yet they seem to get a lot of dirt thrown on them because they are super bloated (since they bring all their dependencies with them).

NixPkgs are also distro agnostic, but they are about as light as regular system packages (.deb/.rpm/.PKG) all the while having an impressive 80 000 packages in their repos.

I don't get why more people aren't using them, sure they do need some tweaking but so do flatpaks, my main theory is that there are no graphical installer for them and the CLI installer is lacking (no progress bar, no ETA, strange syntax) I'm also scared that there is a downside to them I dont know about.

(page 2) 50 comments
sorted by: hot top controversial new old
[–] [email protected] 37 points 8 months ago* (last edited 8 months ago) (2 children)
  1. As you can see from the state of this thread, people see nix or nixpkgs but read nixos. There's no momentum from the community to push it as an extra package manager, while every thread is spammed with nixos.

  2. No gui integrations for casuals. For example Discover integrates flatpaks and snaps, but for nix you need to use the terminal.

  3. The documentation is abysmal. I spent days trying to figure out how to use nix as a declarative package manager before I accidentally came across home-manager. Even the manual leads you down the wrong path. A quick start guide with a few examples for home-manager and flakes, and a few basic commands, would've had me going in 5 minutes. That problem is made worse by the fact that almost all sources of info focus on nixos instead.

Edit:

if anyone's interested in trying it out, here's a part of my other comment in this thread

It's just a list of packages, and an optional flake to control the repositories (stable/unstable) and add packages from outside of the official ones.

To update everything nix related I just run:

cd ~/dotfiles/nix/ && nix flake update && home-manager switch

[–] [email protected] 11 points 8 months ago (4 children)

Yeah, if it wasn't for my niche needs and desires of using my SteamDeck without touching the system partition, I probably wouldn't have messed with Nix because of how much of a confusing mess of modes and switches there are, and I've used terminal based package managers for years. It's very far from the simple "it just works" of Flatpaks.

load more comments (4 replies)
load more comments (1 replies)
[–] [email protected] 5 points 8 months ago (3 children)

NixOS sounds amazing in some regards, but I'm not really interested in learning a whole programming language for it... I have enough to do already.

[–] [email protected] 5 points 8 months ago

The nix package manager can be used on any os and doesn't require usage of the nix programming language..

[–] [email protected] 0 points 8 months ago (1 children)

Did OP mention nixos at some point?

load more comments (1 replies)
load more comments (1 replies)
[–] [email protected] 13 points 8 months ago (1 children)

Part of the reason is that people are still finding out about it, Project has no marketing so it grows organically, in the last year the number of contributors grew by 25 percent.

Another problem is that it still needs polish in term of ease of use, for example it takes me forever to search for packages using the nix-env command but using the website it takes less then a second, That's a basic feature that still does not work correct, Plus their documentation is still not great in my opinion, I actually helped improved it and the improvement they made is still not really good IMO.

load more comments (1 replies)
[–] [email protected] 16 points 8 months ago (4 children)

I maintain some software, and Nix is by far the hardest to deal with. To package config files are relatively complex, and to submit a package you have to download the entire Nix repo, which is huge. Getting a package to build correctly can be a challenge.

It's a pretty large ask for software contributors, who may have to iteract with a half dozen different distros. Now, you could say, leave it to the distro people to do the packaging, but it remains a barrier for entry and is by nature exclusive.

I don't use NixOS, so I have little motivation to stay conversant with Nix and, frankly, it's so demanding I don't bother anymore. I can make RPM, deb, and aur packages trivially, and without having to hold Gb of some package repo (which I otherwise don't use) on my disk.

load more comments (4 replies)
[–] [email protected] 15 points 8 months ago

the aur has everything I need

[–] [email protected] 2 points 8 months ago (1 children)

Was curious myself don't like flatpaks & appimages much, but from a quick googling, they don't seem to integrate with the desktop so you need to launch them from terminal? That is a deal breaker for me at least.

[–] [email protected] 3 points 8 months ago* (last edited 8 months ago) (1 children)

you have to set up the XDG_DATA_DIRS environment variable to take into account ~/.nix-profile/share the desktop icons will only appear after a relogin though.

[–] [email protected] 0 points 8 months ago

It's automatically set up alongside PATH

[–] [email protected] 6 points 8 months ago

yeah, everybody should use them. I usually write my own kernel mods tailored for my hardware and certain needs, I don't know why not everyone is doing that. admittedly is a bit janky maintaining a separate kernel fork, but you get used to it, everyone should do it

[–] [email protected] 8 points 8 months ago

Pacman (and paru and the AUR) and chezmoi works fine, I don't see any reason to switch.

[–] [email protected] 18 points 8 months ago* (last edited 8 months ago) (2 children)

I'm going to go against the grain and say that the Nix and Guix package managers are very good, but they really belong in their respective distros where they're a core part of the system. That'd be Guix System for Guix and NixOS for Nix.

They may have advantages for a foreign distro too, but they are lesser (Guix System can boot into a backup of the system before the last update, for example, but that advantage doesn't exist on, say, Debian.

Also, can we agree to not recommend these systems to new users for the time being? While they're very powerful, they're absolutely designed for power users, and until they're more polished and they have fancy GUIs and stuff for installation and package management, I think it'd be best to keep recommending normal distros like Debian for now.

[–] [email protected] 0 points 8 months ago* (last edited 8 months ago) (2 children)

Guix System can boot into a backup of the system before the last update, for example, but that advantage doesn't exist on, say, Debian.

Yeah, why would I ever want to have bleeding edge userland packages on Debian? Nobody needs something like that or the option to rollback the entire update or pin specific versions of packages...

Also, can we agree to not recommend these systems to new users for the time being?

Did anyone do it in this thread? OP is literally just asking about a list of packages to home-manage. Beginners can most certainly handle it if they don't need a gui to update their system.

load more comments (2 replies)
[–] [email protected] 2 points 8 months ago

You can do rollbacks if you're using something like home-manager on a foreign distribution. It's just a bit more janky admittedly.

[–] [email protected] 10 points 8 months ago (3 children)

For me personally, I just haven't taken any steps into the nix environment. Seems rather complex, setting up those nix files and stuff.

I use Debian on servers and LMDE on my PC, most things I need are in the Debian repos and for other cases I get by pretty good with appimage s and flatpaks. Installing is just a simple command and me happy.

Nixpkgs are probably easy too, I assume. I know a lot of people really like nix, but the effort required to start seems significant to me, especially when we have other methods that just work.

[–] [email protected] 1 points 8 months ago

the effort required to start seems significant to me, especially when we have other methods that just work.

It's just a list of packages, and an optional flake to control the repositories (stable/unstable) and add packages from outside of the official ones.

To update everything nix related I just run:

cd ~/dotfiles/nix/ && nix flake update && home-manager switch

I've only included a few packages from the actual list, but you can see how simple everything is. It just took me days to get to that point because the docs are really bad.

most things I need are in the Debian repos and for other cases I get by pretty good with appimage s and flatpaks.

I use it to freshen up Debian packages. For example Debian docker is like 4 major versions behind the nix one, and it stopped being supported months ago.

Also, now that I've created the list from above, I can just run a single line to reinstall everything I need.

[–] [email protected] 3 points 8 months ago (2 children)

Nixpkgs can be used without knowing anything about nix. You can install almost anything by just running e.g.:

nix-shell -p cowsay

The requirement for that is the nix package manager but that should be easy to install. But yeah getting into Nixos with flakes and all that stuff can be hard.

load more comments (2 replies)
[–] [email protected] -1 points 8 months ago

Why don't you just install nix on debian and see

load more comments
view more: ‹ prev next ›