os/pkgs/psos-docs.nix
2023-01-28 21:49:10 +01:00

28 lines
471 B
Nix

self:
with self;
stdenv.mkDerivation rec {
pname = "psos-docs";
version = "0.0.1";
buildInputs = [
mdbook
mdbook-pdf
];
src = ../docs/..; # wut
phases = ["buildPhase" "installPhase"];
buildPhase = ''
cp -r $src/doc ./doc
cp $src/README.md ./README.md
chmod ug+w -R .
ls -la .
mdbook build doc
'';
installPhase = ''
mkdir -p $out/lib/
cp -r doc/book $out/lib/html
'';
}