Add buildDhall*Package support for generating documentation
The `buildDhall{Directory,GitHub}Package` utilities now take an
optional `document` argument for generating documentation using
`dhall-docs`. The documentation is stored underneath the `./docs`
subdirectory of the build product.
This commit is contained in:
committed by
Emery Hemingway
parent
86b651f169
commit
6dac8e6817
@@ -14,12 +14,17 @@ lib.makePackageOverridable
|
||||
, src
|
||||
, # The file to import, relative to the root directory
|
||||
file ? "package.dhall"
|
||||
# Set to `true` to generate documentation for the package
|
||||
, document ? false
|
||||
}:
|
||||
|
||||
buildDhallPackage {
|
||||
inherit name dependencies source;
|
||||
buildDhallPackage
|
||||
( { inherit name dependencies source;
|
||||
|
||||
code = "${src}/${file}";
|
||||
}
|
||||
code = "${src}/${file}";
|
||||
|
||||
}
|
||||
// lib.optionalAttrs document { documentationRoot = src; }
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user