From af1f07ff03c59b081ff29f069f6c28009dfffad7 Mon Sep 17 00:00:00 2001 From: pennae Date: Tue, 13 Jun 2023 14:05:40 +0200 Subject: [PATCH] nixos/make-options-doc: check for manual paths in options.json since we no longer use the docbook path the check there will no longer fire. add one to optionsJSON to not lose this functionality. --- nixos/lib/make-options-doc/default.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/nixos/lib/make-options-doc/default.nix b/nixos/lib/make-options-doc/default.nix index db0e0a451937..5cfc24533c23 100644 --- a/nixos/lib/make-options-doc/default.nix +++ b/nixos/lib/make-options-doc/default.nix @@ -143,6 +143,14 @@ in rec { $baseJSON $options \ > $dst/options.json + if grep /nixpkgs/nixos/modules $dst/options.json; then + echo "The manual appears to depend on the location of Nixpkgs, which is bad" + echo "since this prevents sharing via the NixOS channel. This is typically" + echo "caused by an option default that refers to a relative path (see above" + echo "for hints about the offending path)." + exit 1 + fi + brotli -9 < $dst/options.json > $dst/options.json.br mkdir -p $out/nix-support