{ pkgs ? import ./pkgs.nix }: let inherit (pkgs) stdenv mobile-nixos-process-doc rsync; # Styles, built from a preprocessor. styles = pkgs.callPackage ./_support/styles { }; # Asciidoc source for the devices section. devices = pkgs.callPackage ./_support/devices { }; # Asciidoc source for the options section. options = pkgs.callPackage ./_support/options { }; in stdenv.mkDerivation { name = "mobile-nixos-docs"; src = ./.; buildInputs = [ mobile-nixos-process-doc rsync ]; buildPhase = '' export LANG=C.UTF-8 # Removes the internal notes. rm -f README.md # Replace it in-place with the repo README. cat >> README.adoc <> README.adoc # The title needs to be first head -n1 ${../CONTRIBUTING.adoc} > contributing.adoc # Then we're adding our common stuff cat >> contributing.adoc <> contributing.adoc if [ ! -e index.adoc ]; then cat >> index.adoc <