Add a flake.nix

This commit is contained in:
Eelco Dolstra 2019-04-08 17:28:05 +02:00
parent 4023ae4cdf
commit a9ceeeb4b0
2 changed files with 19 additions and 1 deletions

18
flake.nix Normal file
View file

@ -0,0 +1,18 @@
{
name = "nix";
description = "The purely functional package manager";
requires = [ flake:nixpkgs ];
provides = flakes: rec {
hydraJobs = import ./release.nix {
nix = flakes.nix; # => flakes.self?
nixpkgs = flakes.nixpkgs;
};
packages.nix = hydraJobs.build.x86_64-linux;
};
}

View file

@ -19,7 +19,7 @@ let
releaseTools.sourceTarball { releaseTools.sourceTarball {
name = "nix-tarball"; name = "nix-tarball";
version = builtins.readFile ./.version; version = builtins.readFile ./.version;
versionSuffix = if officialRelease then "" else "pre${toString nix.revCount}_${nix.shortRev}"; versionSuffix = if officialRelease then "" else "pre${toString nix.revCount or 0}_${nix.shortRev or "0000000"}";
src = nix; src = nix;
inherit officialRelease; inherit officialRelease;