Angle brackets in a Nix flake world
13 days ago
- #Reproducibility
- #Nix
- #Flakes
- Nix community had its first-ever presence at DEFCON33 via nix.vegas.
- Discussion on potential uses of angle brackets (< and >) in Nix with the deprecation of NIX_PATH.
- Current use of angle brackets for importing nixpkgs is a wart on Nix's reproducibility.
- Proposal to repurpose angle brackets for quicker access to current flake attributes.
- Demonstration of overriding __findFile to access flake attributes using angle brackets.
- Initial implementation required --impure flag due to use of builtins.getFlake.
- Simplified pure implementation using self instead of builtins.getFlake.
- New approach provides ergonomic access to flake attributes without extra setup.