[Nix-dev] User environment hooks

Ludovic Courtès ludo at gnu.org
Fri Oct 10 13:43:55 CEST 2008


Hello!

"Andres Loeh" <andres.loeh at googlemail.com>
writes:

> I know I asked and thought about this user environment hook before as well,
> but the longer I work with NixOS, the less I think it's in the spirit of the
> system. Almost all situations I have encountered can be solved with
> functions that do the work, and having functions assigned to it makes the
> compositions of packages clear, whereas dynamic composition in a user
> profile is terribly fragile.

Can you propose a way of handling the GNU Info case?  The goal is to
have a `dir' file that reflects the Info files available to the user.

> I think it is wrong of NixOS to give an UI advantage to packages that are
> composed for you already in all-packages.nix (the advantage being that they
> can easily be queried and installed by the package name rather than the Nix
> attribute name). We should encourage users to compose their own packages,
> because that's part of the strength of NixOS. I have shown in my previous mail
> that often, it is not that hard -- you just have to write a little Nix program
> in your home directory. On the other hand, it's still much harder than using
> nix-env -i directly, and we should think about ways to simplify this approach.

That's true, but OTOH, many people expect to be able to do "nix-env -i"
in the vast majority of cases, just like they used to do "apt-get
install".  Anything beyond that is bound to be considered by many users
as too complex for the task at hand, too intrusive, and/or
counter-intuitive (why would some packages be installable and listable
by `nix-env' while others aren't?).

Thus, I think we should strive to handle common cases in a way that
doesn't require any user intervention beyond "nix-env -i".

Thanks,
Ludo'.




More information about the nix-dev mailing list