hnix/flake.nix

41 lines
958 B
Nix
Raw Normal View History

2022-03-10 06:49:23 +03:00
{
description = "A Haskell re-implementation of the Nix expression language";
inputs = {
2023-11-21 10:14:50 +03:00
nixpkgs.url = "nixpkgs/c757e9bd77b16ca2e03c89bf8bc9ecb28e0c06ad";
2022-03-10 06:49:23 +03:00
nix = {
2022-06-17 10:12:01 +03:00
url = "nix/624e38aa43f304fbb78b4779172809add042b513";
2022-03-10 06:49:23 +03:00
flake = false;
};
};
outputs = {
nix,
nixpkgs,
self,
} @ inp: let
l = builtins //nixpkgs.lib;
2022-06-17 10:12:01 +03:00
supportedSystems = ["x86_64-linux" "aarch64-darwin"];
2022-03-10 06:49:23 +03:00
forAllSystems = f: l.genAttrs supportedSystems
(system: f system (nixpkgs.legacyPackages.${system}));
in {
defaultPackage = forAllSystems
(system: pkgs: import ./default.nix {
inherit pkgs;
withHoogle = true;
2023-11-18 10:13:15 +03:00
compiler = "ghc947";
2022-03-10 06:49:23 +03:00
packageRoot = pkgs.runCommand "hnix-src" {} ''
cp -r ${./.} $out
chmod -R +w $out
cp -r ${nix} $out/data/nix
'';
});
devShell = forAllSystems (system: pkgs: self.defaultPackage.${system}.env);
};
}