mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-12 12:45:27 +03:00
* Consistently include the Nixpkgs revision in the NixOS version
string. svn path=/nixos/trunk/; revision=33729
This commit is contained in:
parent
f9ac67c67f
commit
871b4bd43a
1 changed files with 8 additions and 6 deletions
14
release.nix
14
release.nix
|
@ -4,18 +4,20 @@
|
||||||
|
|
||||||
let
|
let
|
||||||
|
|
||||||
|
versionSuffix = "pre${toString nixosSrc.rev}-${toString nixpkgs.rev}";
|
||||||
|
|
||||||
|
|
||||||
makeIso =
|
makeIso =
|
||||||
{ module, type, description ? type, maintainers ? ["eelco"] }:
|
{ module, type, description ? type, maintainers ? ["eelco"] }:
|
||||||
{ officialRelease ? false
|
{ officialRelease ? false
|
||||||
, system ? "i686-linux"
|
, system ? builtins.currentSystem
|
||||||
}:
|
}:
|
||||||
|
|
||||||
with import <nixpkgs> {inherit system;};
|
with import <nixpkgs> {inherit system;};
|
||||||
|
|
||||||
let
|
let
|
||||||
|
|
||||||
version = builtins.readFile ./VERSION + (if officialRelease then "" else "pre${toString nixosSrc.rev}");
|
version = builtins.readFile ./VERSION + (lib.optionalString (!officialRelease) versionSuffix);
|
||||||
|
|
||||||
versionModule =
|
versionModule =
|
||||||
{ system.nixosVersion = version;
|
{ system.nixosVersion = version;
|
||||||
|
@ -48,12 +50,12 @@ let
|
||||||
makeSystemTarball =
|
makeSystemTarball =
|
||||||
{ module, maintainers ? ["viric"]}:
|
{ module, maintainers ? ["viric"]}:
|
||||||
{ officialRelease ? false
|
{ officialRelease ? false
|
||||||
, system ? "i686-linux"
|
, system ? builtins.currentSystem
|
||||||
}:
|
}:
|
||||||
|
|
||||||
with import <nixpkgs> {inherit system;};
|
with import <nixpkgs> {inherit system;};
|
||||||
let
|
let
|
||||||
version = builtins.readFile ./VERSION + (if officialRelease then "" else "pre${toString nixosSrc.rev}");
|
version = builtins.readFile ./VERSION + (lib.optionalString (!officialRelease) versionSuffix);
|
||||||
|
|
||||||
versionModule = { system.nixosVersion = version; };
|
versionModule = { system.nixosVersion = version; };
|
||||||
|
|
||||||
|
@ -113,7 +115,7 @@ let
|
||||||
|
|
||||||
src = nixosSrc;
|
src = nixosSrc;
|
||||||
|
|
||||||
inherit officialRelease;
|
inherit officialRelease versionSuffix;
|
||||||
|
|
||||||
buildInputs = [ nixUnstable ];
|
buildInputs = [ nixUnstable ];
|
||||||
|
|
||||||
|
@ -124,7 +126,7 @@ let
|
||||||
'';
|
'';
|
||||||
|
|
||||||
distPhase = ''
|
distPhase = ''
|
||||||
releaseName=nixos-$VERSION$VERSION_SUFFIX-${toString nixpkgs.rev}
|
releaseName=nixos-$VERSION$VERSION_SUFFIX
|
||||||
ensureDir "$out/tarballs"
|
ensureDir "$out/tarballs"
|
||||||
mkdir ../$releaseName
|
mkdir ../$releaseName
|
||||||
cp -prd . ../$releaseName/nixos
|
cp -prd . ../$releaseName/nixos
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue