News for hackers. Stuff that matters.
Re:Mobile NixOS: The Present and the Future by taktoa on Saturday August 24, 2019 @01:21PM (#20788402)
That's actually just a command line infelicity; the advice to use `nix-env -i foobar` is really misguided, and you can avoid excessive memory usage by doing `nix-env -iA nixos.foobar` (or `nixpkgs.foobar` if you are using it on a non-NixOS machine). The difference is that in the former case, `foobar` is a regular expression that is being matched against the `name` field of every package in nixpkgs, whereas in the latter case, `foobar` is an attribute path that is used to traverse the nested Nix objects that make up nixpkgs. Since Nix is lazy, the former results in evaluating a LOT of stuff, whereas the latter does not.
Re:Mobile NixOS: The Present and the Future by kstenerud on Saturday August 24, 2019 @05:24PM (#20789804)
Even if it were evaluating the entire library of Congress, there's no valid reason for it to consume gigabytes of memory. I really can't understand why this is so...