mirror of
https://github.com/nix-community/home-manager.git
synced 2025-11-08 19:46:05 +01:00
docs: rename generated manual to index.xhtml
The `nixos-render-docs` tool outputs XHTML formatted content. In order to convince browsers like `firefox` to treat the data as XHTML the extension must be `.xhtml` and not `.html`. Using the XHTML-formatted content as HTML is mainly an issue with self-closing `<a />` tags.
This commit is contained in:
parent
0a71046493
commit
613dbb35db
3 changed files with 18 additions and 8 deletions
|
|
@ -1,6 +1,9 @@
|
|||
{ writeShellScriptBin, makeDesktopItem, symlinkJoin }:
|
||||
{ html, pathName ? "home-manager", projectName ? pathName
|
||||
, name ? "${pathName}-help" }:
|
||||
{ html
|
||||
, pathName ? "home-manager"
|
||||
, projectName ? pathName
|
||||
, name ? "${pathName}-help"
|
||||
}:
|
||||
let
|
||||
helpScript = writeShellScriptBin name ''
|
||||
set -euo pipefail
|
||||
|
|
@ -18,7 +21,7 @@ let
|
|||
echo "$0: unable to start a web browser; please set \$BROWSER"
|
||||
exit 1
|
||||
else
|
||||
exec "$BROWSER" "${html}/share/doc/${pathName}/index.html"
|
||||
exec "$BROWSER" "${html}/share/doc/${pathName}/index.xhtml"
|
||||
fi
|
||||
'';
|
||||
|
||||
|
|
@ -30,7 +33,8 @@ let
|
|||
exec = "${helpScript}/bin/${name}";
|
||||
categories = [ "System" ];
|
||||
};
|
||||
in symlinkJoin {
|
||||
in
|
||||
symlinkJoin {
|
||||
inherit name;
|
||||
paths = [ helpScript desktopItem ];
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue