[Nix-dev] Re: environment.systemPackages

Benjamin Franksen benjamin.franksen at helmholtz-berlin.de
Fri Mar 4 16:34:24 CET 2011


Eelco Dolstra wrote:
>> How can I make the pkgs variable visible here?
> 
> Add the following line to the top of the file:
> 
>    { pkgs, ... }:
> 
> Lots of examples of configurations can be found here:
> https://svn.nixos.org/repos/nix/configurations/trunk/

Thanks. I looked at these examples and saw such a line but, well... I just 
didn't think this could work. I mean, with this addition 
/etc/nixos/configuration.nix becomes a function, right? Is there a special 
trick that makes nixos interpret the code as either a function or a plain 
value?

Please forgive my beginner's confusion, I have some problems groking the nix 
language (the only functional languages I know are all statically typed).

Cheers
Ben




More information about the nix-dev mailing list