mirror of
https://github.com/NixOS/nix-pills
synced 2024-09-19 04:00:13 -04:00
Add proper versioning
This commit is contained in:
parent
f54a8b7632
commit
6be6381643
|
@ -1,4 +1,4 @@
|
||||||
{ pkgs ? import <nixpkgs> {} }:
|
{ pkgs ? import <nixpkgs> {}, revCount, shortRev }:
|
||||||
let
|
let
|
||||||
lib = pkgs.lib;
|
lib = pkgs.lib;
|
||||||
sources = lib.sourceFilesBySuffices ./. [ ".xml" ".txt" ];
|
sources = lib.sourceFilesBySuffices ./. [ ".xml" ".txt" ];
|
||||||
|
@ -7,6 +7,7 @@ let
|
||||||
{
|
{
|
||||||
buildInputs = [ pkgs.libxml2 ];
|
buildInputs = [ pkgs.libxml2 ];
|
||||||
meta.description = "Nix Pills with as a single docbook file";
|
meta.description = "Nix Pills with as a single docbook file";
|
||||||
|
inherit revCount shortRev;
|
||||||
}
|
}
|
||||||
''
|
''
|
||||||
cp -r ${sources} ./sources
|
cp -r ${sources} ./sources
|
||||||
|
@ -14,7 +15,7 @@ let
|
||||||
|
|
||||||
cd sources
|
cd sources
|
||||||
|
|
||||||
printf "%s" "1" > version
|
printf "%s-%s" "$revCount" "$shortRev" > version
|
||||||
xmllint --xinclude --output $out ./book.xml
|
xmllint --xinclude --output $out ./book.xml
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
|
11
release.nix
11
release.nix
|
@ -1,7 +1,16 @@
|
||||||
|
{ nix-pills ? { outPath = ./.; revCount = 1234; shortRev = "abcdef"; }
|
||||||
|
, nixpkgs ? { outPath = <nixpkgs>; revCount = 1234; shortRev = "abcdef"; }
|
||||||
|
, officialRelease ? false
|
||||||
|
}:
|
||||||
|
|
||||||
let
|
let
|
||||||
pkgs = import <nixpkgs> { };
|
pkgs = import <nixpkgs> { };
|
||||||
in rec {
|
in rec {
|
||||||
html-split = import ./default.nix { inherit pkgs; };
|
html-split = import ./default.nix {
|
||||||
|
inherit pkgs;
|
||||||
|
|
||||||
|
inherit (nix-pills) revCount shortRev;
|
||||||
|
};
|
||||||
|
|
||||||
release = pkgs.releaseTools.aggregate
|
release = pkgs.releaseTools.aggregate
|
||||||
{ name = "nix-pills-release";
|
{ name = "nix-pills-release";
|
||||||
|
|
Loading…
Reference in a new issue