Nix (command): Difference between revisions

imported>Fricklerhandwerk
nix -> Nix package manager
imported>Gdamjan
No edit summary
Line 19: Line 19:
in <code>~/.config/nix/nix.conf</code>.
in <code>~/.config/nix/nix.conf</code>.


Or system-wide with
On NixOS you can't edit <code>/etc/nix/nix.conf</code> directly, but you can enable this feature by editing <code>/etc/nixos/configuration.nix</code>:
<syntaxHighlight lang=nix>
<syntaxHighlight lang=nix>
# /etc/nix/nix.conf
#  
{ pkgs, ... }: {
{ pkgs, ... }: {
  nix.extraOptions = ''
  …
      experimental-features = nix-command
  nix.settings.experimental-features = [ "nix-command" ];
  '';
  …
}
}
</syntaxHighlight>
</syntaxHighlight>
in <code>/etc/nix/nix.conf</code> on NixOS.
and then run <code>sudo nixos-rebuild switch</code> as always.


[[Category:Nix]]
[[Category:Nix]]