Mehrad,
@Mehrad@fosstodon.org avatar

Yesterday a good friend of mine helped me to understand and toy around with Gnu in a VM as I'm very hesitant to add anything to my daily driver machine. All things considered, I'm >90% convinced.

But here is a question for the friends and the community: What are the advantages of Nix over Guix (apart from number of packages)?

P.s: I'm going to have it on an Arch-based machine to add reproducibility to my projects. It will not handle my OS packages.

sandro,
@sandro@c3d2.social avatar

@Mehrad NixOS is using a standard service manager that people are familiar with.
It also doesn't exclude unfree packages but they are highly preferred. If there is not other way, it also ships prebuild binaries.
It is easy to contribute to. No need to fiddle with mailing lists or git mail. You did a mistake? Just force push your PR, no one cares. You did that 7 times in a row? 🤷
By default it uses a LTS kernel where most hardware just works, not the libre kernel which breaks many OOT modules

sandro,
@sandro@c3d2.social avatar

@Mehrad the packages I have seen so far written for guix where extremely verbose and boiler platy.
Where in nixpkgs you just write hash = "..." you wrote in guix that it is a fod, has a hash and that hash has that type and that value. Also the python environment that package was constructing repeated every package as a string and a variable. Very redundant.

kirschwipfel,
@kirschwipfel@nerdculture.de avatar

Re hash: specifying the type is future prove as it allows to change the hash algorithm without introducing any magic like prefixes.

Re redundancy in listing package inputs: this was removed a year ago or even earlier.
@sandro @Mehrad

sandro, (edited )
@sandro@c3d2.social avatar

@kirschwipfel @Mehrad I wouldn't consider prefixes magic, they are just prefixes and since hashing is handled by nix anyway, this gives the most flexibility with the least amount of code in the packages themselves.

for context I mean this https://git.sr.ht/~mediagoblin/mediagoblin/tree/master/item/guix-env.scm#L191-218 here

soupglasses,

@Mehrad Guix does not ship nongnu (unfree) packages like Steam and Nvidia drivers.

Personally i like the terseness of Nix's language compared to Guix's lisp base.

Its good to remember that Guix is more a fork of Nix that then built its ideas on top in Lisp with its own package-set.

In all, if you are okay with or like Guix's limitations, its really hard to go wrong with it. But equally so, Nix is also a solid choice that is also hard to go wrong with. Neither is "better" than the other.

sandro,
@sandro@c3d2.social avatar

@soupglasses @Mehrad for someone coming from an Arch, a Debian or a Red hat, NixOS is probably more familiar and easier to get started with.

soupglasses,

@sandro @Mehrad Yeah. Guix runs Shepherd instead of SystemD for example. This can be a big limiting factor for example if you are running servers that you want to isolate with f.x. cgroups. Shepherd may have something similar, but i have failed to find anything similar. :blobfoxthink:

sandro,
@sandro@c3d2.social avatar

@soupglasses @Mehrad People are already turned off by having to learn the nix language (which a beginner doesn't need to know to much about other than the general syntax and a few things here and there) but having to learn Shepard is a whole other level. You suddenly can't just copy things from the internet anymore and upstream projects are probably like: what are you using? Can you try systemd?

soupglasses,

@sandro @Mehrad Nix's language is great. How it teaches itself causes years worth of pain for anyone getting into it alone.

I wish i could write proper official docs to help people learn. I had to learn from watching videos of prominent people in the NixOS space doing random Nix stuff, just listening to all the small comments as much as possible. :blobfoxsad:

Mehrad,
@Mehrad@fosstodon.org avatar

@sandro @soupglasses

Yeah, but note that I'm not going to use it as my system's package manager. It is just going to be used for my projects. One profile per project. This is to be able to make sure I have reproducible environment for my project as I might have to get back to some of them after few years and I need the same exact software stack to run them.

So my use-case is not managing my main software. So I will still use systemd and will use pacman.

Mehrad, (edited )
@Mehrad@fosstodon.org avatar

@soupglasses
Thanks for the comment. Regarding the non-free, Guix actually has non-free channels, although everything I need for my projects are already packaged in Guix main channel.

Regarding the lisp language, I'm actually a big fan of lisp, but guile has some notations that are imho distasteful (e.g key-value pairs syntax). But it is not that big a deal.

Regarding the "Guix's limitations", I'm not aware of any (hence my post), so is there any resources I can read/watch/listen?

soupglasses,

@Mehrad The above was the "limitations". I have an nvidia graphics card for example on one of my machines, making it pretty much go out the window.

Also it is important to state that Guix does not have non-free channels. There is a community effort outside of Guix to have a nongnu/nonfree repo, but you are not allowed to explicitly talk or link to it in Guix official channels.

Mehrad,
@Mehrad@fosstodon.org avatar

@soupglasses Well, there is one obvious limitation, but I guess both and suffer from it equally: running out of inodes.

I did a stupid quick comparison between my daily driver Arch-based computer and my friend who lives inside Emacs, exwm and Guix. I had 2.7k symlinks on my entire machine, and he had 270k symlinks (this is after guix gc)!

soupglasses,

@Mehrad Yeah. My advice is to think "Do you want to write Guile or Nix", as that is gonna be the primary one to boil it down to.

Only other one to consider is the guix cli vs nix3 cli. Both work well, Guix is a bit more lax with how experimental it lets itself be, but not in any really worrying way.

Personally I am a big fan of Nix's Flakes interface, which Guix has no feature-set similar to.

Mehrad,
@Mehrad@fosstodon.org avatar

@soupglasses Thanks. I might give Nix a go in a VM as well and see how it goes. I'm definitely more familiar with Guile (considering my elisp and common lisp experience), but I'm open to learning/experiencing new things.

One anecdote: I had a blog about 12 years ago named nixsos.com and since [I think] last year, I have redirected my domain to discourse.nixos.org 😅 If you know a better URI for redirection or if anyone wants to use it, let me know. Kinda my donation to Nix project.

efraim,

@Mehrad @soupglasses I deal with the inode problem by using btrfs as an ext4 drop-in replacement, with minimal compression. No snapshots, no subvolumes, no special anything. I've added a cron job to nightly clear up a small number of blocks.

Mehrad,
@Mehrad@fosstodon.org avatar

The reason I'm not concerned about number of packages is that:

  1. At the time of writing this, it has 24527 packages (source: https://repology.org/repository/gnuguix )

  2. It already has all the software I need for my projects packaged. The rest are cherry on the top imho

There is also this very brief comparison, although considering the org-mode format of the file, they might be a tad bit bias 😜 :

https://gist.github.com/abcdw/e54807b0a25e61fe2cf1bf8991410f83

moheb2000,

@Mehrad
I'm agree with "Inconsistent nix cli". When I installed Nix sometime ago, I had no idea what was the best way to install a package in Nix! But about package number, most of the packages in guix start with emacs- and are originally emacs packages! So I think removing them from package count will give us a better comparison!

Mehrad,
@Mehrad@fosstodon.org avatar

@moheb2000 I'm n00b in both Guix and Nix, but I also got this comment :ablobcateyesflip: :

https://bsd.network/@solene/110758340980847193

moheb2000,

@Mehrad
I didn't remember that! Yes, that's correct, too!

soupglasses,

@Mehrad Another great thing with Nix-like packaging is how easy it is to do as well.

Is a package you want not in there? Well you can add it with 10 minutes of your time and a PR. I know nixpkgs further also includes an automatic test suite and auto-created PRs for updates to simplify the maintenance process further. Making it a blast to package and maintain stuff.

:blobfoxlurk:

  • All
  • Subscribed
  • Moderated
  • Favorites
  • guix
  • DreamBathrooms
  • InstantRegret
  • ethstaker
  • magazineikmin
  • GTA5RPClips
  • rosin
  • modclub
  • Youngstown
  • ngwrru68w68
  • slotface
  • osvaldo12
  • kavyap
  • mdbf
  • thenastyranch
  • JUstTest
  • everett
  • cubers
  • cisconetworking
  • normalnudes
  • Durango
  • anitta
  • khanakhh
  • tacticalgear
  • tester
  • provamag3
  • megavids
  • Leos
  • lostlight
  • All magazines