{ pkgs, stdenv, lib, graphviz, plantuml, python3, sphinx }: let pyenv = pkgs.buildEnv { name = "sphinx-env"; nativeBuildInputs = [ sphinx python3.pkgs.sphinxcontrib_plantuml ]; }; in stdenv.mkDerivation rec { version = "0.0"; name = "privatestorageio-${version}"; src = lib.cleanSource ../.; phases = [ "unpackPhase" "buildPhase" ]; depsBuildBuild = [ pyenv ]; buildPhase = '' sphinx-build -W docs/source $out/docs ''; }