Software:Nix (package manager)
Initial release | June 15, 2003 |
---|---|
Stable release | 2.19.2[1]
/ November 29, 2023 |
Written in | C++ |
Platform | Linux, Unix-like |
Type | Package management |
License | LGPL |
Website | nixos |
Nix is a cross-platform package manager that uses a deployment model where software is installed into unique directories generated through cryptographic hashes. It is also the name of the tool's programming language. A package's hash takes into account the dependencies, which is claimed to eliminate dependency hell,[2] as an alternative to the typical solution of installing multiple versions of dependencies at the same time. This package management model advertises more reliable, reproducible, and portable packages.[3][4]
Nix packages are defined through a lazy functional programming language specifically designed for package management. Dependencies are tracked directly in this language through an intermediate format called "derivations". A Nix environment keeps track of references automatically, which allows unused packages to be garbage collected when no other package depends on them. At the cost of greater storage requirements, all upgrades in Nix are guaranteed to be both atomic and capable of efficient rollback. This also enables multiple users to safely install software on the same system without administrator privileges.
Nix has full support for Linux and macOS and can safely be installed side by side with an existing package manager.
Nix is used for software packaging and distribution in CERN's LHCb experiment.[5]
NixOS
NixOS[6] is a Linux distribution using Nix for managing software in the system, including the Linux kernel.[7]
Nixpkgs
Nixpkgs is the package repository built upon the Nix package manager. According to Repology, as of March 2023 it contains more than 80,000 packages[8] and has a higher number of up-to-date packages than any other package repository.[9] Architectures supported by Nixpkgs are x86_64-linux, aarch64-linux, x86_64-darwin and aarch64-darwin. Packages for these architectures are regularly built, using a continuous integration service called Hydra,[10] and the results of these builds are uploaded to a public binary cache.[11] When Nix installs a package, it checks this cache and downloads the package from there instead of building it locally.
Nixpkgs is developed in a single git repository on GitHub.[12] Beside packages, it also contains the source code for NixOS.
See also
- GNU Guix: another declarative package manager, using GNU Guile for configuration and customization
- Maak: a build automation utility similar to make, designed to build complex software systems
- Runbook automation
References
- ↑ "Release 2.15.2 · NixOS/Nix" (in en). https://github.com/NixOS/nix/releases/tag/2.15.2.
- ↑ Prins, Pjotr; Suresh, Jeeva; Dolstra, Eelco (22 December 2008). "Nix fixes dependency hell on all Linux distributions". https://www.linux.com/news/nix-fixes-dependency-hell-all-linux-distributions/.
- ↑ Dolstra, Eelco; de Jonge, Merijn; Visser, Eelco (November 2004). "Nix: A Safe and Policy-Free System for Software Deployment". pp. 79–92. https://edolstra.github.io/pubs/nspfssd-lisa2004-final.pdf. Retrieved 11 July 2023.
- ↑ Dolstra, Eelco (2006). The Purely Functional Software Deployment Model (PDF) (Ph.D.). Utrecht University. Retrieved 11 July 2023.
- ↑ Burr, Chris; Clemencic, Marco; Couturier, Ben (2018). "Software packaging and distribution for LHCb using Nix". https://cds.cern.ch/record/2700235/files/10.1051_epjconf_201921405005.pdf.
- ↑ "Nix & NixOS | Reproducible builds and deployments". https://nixos.org/.
- ↑ Dolstra, Eelco; Löh, Andres; Pierron, Nicolas (September 2008). "NixOS: A Purely Functional Linux Distribution". ICFP 2008: 13th ACM SIGPLAN International Conference on Functional Programming. pp. 367–378. https://edolstra.github.io/pubs/nixos-jfp-final.pdf.
- ↑ "Nixpkgs unstable repository information - Repology". https://repology.org/repository/nix_unstable.
- ↑ "Repository statistics - Repology". https://repology.org/repositories/statistics/newest.
- ↑ "RFC 0046 - Platform Support Tiers". https://github.com/NixOS/rfcs/blob/master/rfcs/0046-platform-support-tiers.md.
- ↑ "NixOS official binary cache". http://cache.nixos.org/.
- ↑ "Nixpkgs github repository". https://github.com/NixOS/nixpkgs.
External links
- Nixpkgs GitHub repository
- Debian developer criticism (2008)
- Purely Functional Configuration Management with Nix and NixOS, InfoQ, 2014
- My NixOS Desktop Flow, Xe Iaso, 2020
Original source: https://en.wikipedia.org/wiki/Nix (package manager).
Read more |