mirror of
https://git.gay/pyrox/aux-docs
synced 2024-11-23 02:37:56 +00:00
lib-doc -> lib-docs
This commit is contained in:
parent
111239c73b
commit
dffb62de95
|
@ -1,8 +1,13 @@
|
||||||
# Generates the documentation for library functions via nixdoc.
|
# Generates the documentation for library functions via nixdoc.
|
||||||
{ pkgs, inputs, ... }:
|
{
|
||||||
|
pkgs,
|
||||||
|
inputs,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}:
|
||||||
let
|
let
|
||||||
|
|
||||||
inherit (pkgs) stdenv lib nixdoc;
|
inherit (pkgs) stdenv nixdoc;
|
||||||
|
|
||||||
in
|
in
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
|
@ -17,9 +22,9 @@ stdenv.mkDerivation {
|
||||||
description=$3
|
description=$3
|
||||||
# TODO: wrap lib.$name in <literal>, make nixdoc not escape it
|
# TODO: wrap lib.$name in <literal>, make nixdoc not escape it
|
||||||
if [[ -e "../lib/$baseName.nix" ]]; then
|
if [[ -e "../lib/$baseName.nix" ]]; then
|
||||||
nixdoc -c "$name" -d "lib.$name: $description" -l ${pkgs.doc-locations-json} -f "$baseName.nix" > "$out/$name.md"
|
nixdoc -c "$name" -d "lib.$name: $description" -l ${pkgs.amg.doc-locations-json} -f "$baseName.nix" > "$out/$name.md"
|
||||||
else
|
else
|
||||||
nixdoc -c "$name" -d "lib.$name: $description" -l ${pkgs.doc-locations-json} -f "$baseName/default.nix" > "$out/$name.md"
|
nixdoc -c "$name" -d "lib.$name: $description" -l ${pkgs.amg.doc-locations-json} -f "$baseName/default.nix" > "$out/$name.md"
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -34,6 +39,6 @@ stdenv.mkDerivation {
|
||||||
''
|
''
|
||||||
docgen ${name} ${baseName} ${lib.escapeShellArg description}
|
docgen ${name} ${baseName} ${lib.escapeShellArg description}
|
||||||
''
|
''
|
||||||
) pkgs.libsets}
|
) lib.amg.libsets}
|
||||||
'';
|
'';
|
||||||
}
|
}
|
Loading…
Reference in a new issue