From 525b598ce37688ed7c19c4bfd82850688d41a1d8 Mon Sep 17 00:00:00 2001 From: Robert Hensing Date: Mon, 5 Oct 2020 17:38:48 +0200 Subject: [PATCH] flake: Add overlay --- flake.nix | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/flake.nix b/flake.nix index 8388e0b..d711a13 100644 --- a/flake.nix +++ b/flake.nix @@ -9,14 +9,21 @@ "x86_64-darwin" "x86_64-linux" ]; + arionFromPkgs = pkgs: import ./nix/arion.nix { inherit pkgs; }; in { + # The overlay is currently the recommended way to integrate arion, + # because its arion attribute behaves just like Nixpkgs. + overlay = final: prev: { + arion = arionFromPkgs final; + }; + packages = lib.genAttrs systems (system: let pkgs = nixpkgs.legacyPackages.${system}; in { - arion = import ./nix/arion.nix { inherit pkgs; }; + arion = arionFromPkgs pkgs; }); # Does not include the eval and build functions like you may expect from Nixpkgs.