Nix (package manager): Difference between revisions
m →Nix store: typo Tags: Mobile edit Mobile web edit |
m Focus on NixOS, and assumed that Nix 2.0 is used by most people now, so reordered the information. Home-Manager is not used outside Nixos (this is misleading), its used as addition to nixos in cases the nix-options arent enough. |
||
| Line 5: | Line 5: | ||
=== Installation === | === Installation === | ||
NixOS: Nix is being installed while NixOS is being installed. | |||
The [https://nixos.org/manual/nix/stable/installation/ installation section of the Nix manual] describes the installation of standalone Nix from binary or source | If you intend to utilize Nix on a different Linux distribution or a Mac computer, you can perform a standalone installation: The [https://nixos.org/manual/nix/stable/installation/ installation section of the Nix manual] describes the installation of standalone Nix from binary or source. | ||
=== Nix commands === | === Nix commands === | ||
The [[Nix command|Nix commands]] are documented in the [https://nixos.org/manual/nix/stable/command-ref/experimental-commands.html Nix reference manual]. Prior to version 2.0 (February 2018) there have been different commands. | |||
=== Configuration === | === Configuration === | ||
| Line 17: | Line 18: | ||
Standalone Nix is configured through <code>nix.conf</code> (usually found in <code>/etc/nix/</code>), which defines a number of settings relating to evaluation, builds, garbage collection, sandboxing, and user permissions. Details on the available options are [https://nixos.org/manual/nix/stable/command-ref/conf-file found in the Nix reference manual]. | Standalone Nix is configured through <code>nix.conf</code> (usually found in <code>/etc/nix/</code>), which defines a number of settings relating to evaluation, builds, garbage collection, sandboxing, and user permissions. Details on the available options are [https://nixos.org/manual/nix/stable/command-ref/conf-file found in the Nix reference manual]. | ||
Even further configuration is possible with [[Home Manager]] to manage declarative environments for a single user. For system-wide configuration on Linux, you can use [https://github.com/numtide/system-manager System Manager]. For system-wide configuration on macOS, [https://github.com/LnL7/nix-darwin nix-darwin] is the preferred solution. | |||
== Internals == | == Internals == | ||