mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-28 18:03:04 +00:00
nixpkgs manual: extract some build paths
Co-authored-by: Shahar "Dawn" Or <mightyiampresence@gmail.com>
This commit is contained in:
parent
821c72743c
commit
13aeddb926
4
doc/common.nix
Normal file
4
doc/common.nix
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
{
|
||||||
|
outputPath = "share/doc/nixpkgs";
|
||||||
|
indexPath = "manual.html";
|
||||||
|
}
|
@ -3,6 +3,8 @@ let
|
|||||||
inherit (pkgs) lib;
|
inherit (pkgs) lib;
|
||||||
inherit (lib) hasPrefix removePrefix;
|
inherit (lib) hasPrefix removePrefix;
|
||||||
|
|
||||||
|
common = import ./common.nix;
|
||||||
|
|
||||||
lib-docs = import ./doc-support/lib-function-docs.nix {
|
lib-docs = import ./doc-support/lib-function-docs.nix {
|
||||||
inherit pkgs nixpkgs;
|
inherit pkgs nixpkgs;
|
||||||
libsets = [
|
libsets = [
|
||||||
@ -132,15 +134,15 @@ in pkgs.stdenv.mkDerivation {
|
|||||||
'';
|
'';
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
dest="$out/share/doc/nixpkgs"
|
dest="$out/${common.outputPath}"
|
||||||
mkdir -p "$(dirname "$dest")"
|
mkdir -p "$(dirname "$dest")"
|
||||||
mv out "$dest"
|
mv out "$dest"
|
||||||
mv "$dest/index.html" "$dest/manual.html"
|
mv "$dest/index.html" "$dest/${common.indexPath}"
|
||||||
|
|
||||||
cp ${epub} "$dest/nixpkgs-manual.epub"
|
cp ${epub} "$dest/nixpkgs-manual.epub"
|
||||||
|
|
||||||
mkdir -p $out/nix-support/
|
mkdir -p $out/nix-support/
|
||||||
echo "doc manual $dest manual.html" >> $out/nix-support/hydra-build-products
|
echo "doc manual $dest ${common.indexPath}" >> $out/nix-support/hydra-build-products
|
||||||
echo "doc manual $dest nixpkgs-manual.epub" >> $out/nix-support/hydra-build-products
|
echo "doc manual $dest nixpkgs-manual.epub" >> $out/nix-support/hydra-build-products
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user