mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-09-20 04:19:00 +02:00
lib.types.functionTo: Add pseudo-attr to generated docs
This commit is contained in:
parent
06da97fc3a
commit
062bc5e74a
|
@ -526,7 +526,7 @@ rec {
|
|||
check = isFunction;
|
||||
merge = loc: defs:
|
||||
fnArgs: (mergeDefinitions (loc ++ [ "[function body]" ]) elemType (map (fn: { inherit (fn) file; value = fn.value fnArgs; }) defs)).mergedValue;
|
||||
getSubOptions = elemType.getSubOptions;
|
||||
getSubOptions = prefix: elemType.getSubOptions (prefix ++ [ "[function body]" ]);
|
||||
getSubModules = elemType.getSubModules;
|
||||
substSubModules = m: functionTo (elemType.substSubModules m);
|
||||
functor = (defaultFunctor "functionTo") // { wrapped = elemType; };
|
||||
|
|
|
@ -20,7 +20,19 @@
|
|||
<title>Configuration Options</title>
|
||||
<variablelist xml:id="configuration-variable-list">
|
||||
<xsl:for-each select="attrs">
|
||||
<xsl:variable name="id" select="concat('opt-', str:replace(str:replace(str:replace(str:replace(attr[@name = 'name']/string/@value, '*', '_'), '<', '_'), '>', '_'), ':', '_'))" />
|
||||
<xsl:variable name="id" select="
|
||||
concat('opt-',
|
||||
str:replace(str:replace(str:replace(str:replace(str:replace(str:replace(str:replace(
|
||||
attr[@name = 'name']/string/@value,
|
||||
'*', '_'),
|
||||
'<', '_'),
|
||||
' ', '_'),
|
||||
'>', '_'),
|
||||
'[', '_'),
|
||||
']', '_'),
|
||||
':', '_')
|
||||
)
|
||||
" />
|
||||
<varlistentry>
|
||||
<term xlink:href="#{$id}">
|
||||
<xsl:attribute name="xml:id"><xsl:value-of select="$id"/></xsl:attribute>
|
||||
|
|
Loading…
Reference in a new issue