Jump to content

Translations:Flakes/191/en: Difference between revisions

From Official NixOS Wiki
FuzzyBot (talk | contribs)
Importing a new version from external source
Tags: Mobile edit Mobile web edit
 
FuzzyBot (talk | contribs)
Importing a new version from external source
Tags: Replaced Mobile edit Mobile web edit
 
Line 1: Line 1:
=== Nix configuration ===
=== Nix configuration ===
It is possible to override the global Nix configuration set in your <code>nix.conf</code> file for the purposes of evaluating a flake. This can be useful, for example, for setting up binary caches specific to certain projects, while keeping the global configuration untouched. The flake file can contain a nixConfig attribute with any relevant configuration settings supplied. For example, enabling the nix-community binary cache would be achieved by:
{{File|3=<nowiki>{
  ...
  nixConfig = {
    extra-substituters = [
      "https://nix-community.cachix.org"
    ];
    extra-trusted-public-keys = [
      "nix-community.cachix.org-1:...="
    ];
  }
}</nowiki>|name=flake.nix|lang=nix}}{{Note|If you are used to configuring your Nix settings via the NixOS configuration, these options are under <code>nix.settings</code> and not <code>nix</code>. For example, you cannot specify the automatic storage optimisation under <code>nix.optimisation.enable</code>.}}

Latest revision as of 19:10, 31 October 2025

Message definition (Flakes)
=== Nix configuration ===

Nix configuration