diff options
author | Bobby Rong <rjl931189261@126.com> | 2021-07-04 09:11:53 +0800 |
---|---|---|
committer | Bobby Rong <rjl931189261@126.com> | 2021-07-04 09:11:53 +0800 |
commit | ef37170c6dee5ce3c98126e12d09541fdf1e82ea (patch) | |
tree | 7a10b65f70f8ee2b7355e848e541ea9480c8fd3b /nixos/doc/manual/from_md/configuration | |
parent | 800c1f15a3ad3cbbce948d652b46406adeb2fc56 (diff) | |
download | nixpkgs-ef37170c6dee5ce3c98126e12d09541fdf1e82ea.tar nixpkgs-ef37170c6dee5ce3c98126e12d09541fdf1e82ea.tar.gz nixpkgs-ef37170c6dee5ce3c98126e12d09541fdf1e82ea.tar.bz2 nixpkgs-ef37170c6dee5ce3c98126e12d09541fdf1e82ea.tar.lz nixpkgs-ef37170c6dee5ce3c98126e12d09541fdf1e82ea.tar.xz nixpkgs-ef37170c6dee5ce3c98126e12d09541fdf1e82ea.tar.zst nixpkgs-ef37170c6dee5ce3c98126e12d09541fdf1e82ea.zip |
nixos: use only URI fragment in manual options links
Diffstat (limited to 'nixos/doc/manual/from_md/configuration')
-rw-r--r-- | nixos/doc/manual/from_md/configuration/config-file.section.xml | 6 | ||||
-rw-r--r-- | nixos/doc/manual/from_md/configuration/modularity.section.xml | 20 |
2 files changed, 12 insertions, 14 deletions
diff --git a/nixos/doc/manual/from_md/configuration/config-file.section.xml b/nixos/doc/manual/from_md/configuration/config-file.section.xml index b7ba17b8cee..952c6e60030 100644 --- a/nixos/doc/manual/from_md/configuration/config-file.section.xml +++ b/nixos/doc/manual/from_md/configuration/config-file.section.xml @@ -37,9 +37,9 @@ <para> Sets can be nested, and in fact dots in option names are shorthand for defining a set containing another set. For instance, - <link xlink:href="options.html#opt-services.httpd.enable"><literal>services.httpd.enable</literal></link> - defines a set named <literal>services</literal> that contains a set - named <literal>httpd</literal>, which in turn contains an option + <xref linkend="opt-services.httpd.enable" /> defines a set named + <literal>services</literal> that contains a set named + <literal>httpd</literal>, which in turn contains an option definition named <literal>enable</literal> with value <literal>true</literal>. This means that the example above can also be written as: diff --git a/nixos/doc/manual/from_md/configuration/modularity.section.xml b/nixos/doc/manual/from_md/configuration/modularity.section.xml index d5db37c13cf..a7688090fcc 100644 --- a/nixos/doc/manual/from_md/configuration/modularity.section.xml +++ b/nixos/doc/manual/from_md/configuration/modularity.section.xml @@ -40,12 +40,12 @@ <para> Note that both <literal>configuration.nix</literal> and <literal>kde.nix</literal> define the option - <link xlink:href="options.html#opt-environment.systemPackages"><literal>environment.systemPackages</literal></link>. - When multiple modules define an option, NixOS will try to + <xref linkend="opt-environment.systemPackages" />. When multiple + modules define an option, NixOS will try to <emphasis>merge</emphasis> the definitions. In the case of - <link xlink:href="options.html#opt-environment.systemPackages"><literal>environment.systemPackages</literal></link>, - that’s easy: the lists of packages can simply be concatenated. The - value in <literal>configuration.nix</literal> is merged last, so for + <xref linkend="opt-environment.systemPackages" />, that’s easy: the + lists of packages can simply be concatenated. The value in + <literal>configuration.nix</literal> is merged last, so for list-type options, it will appear at the end of the merged list. If you want it to appear first, you can use <literal>mkBefore</literal>: @@ -60,7 +60,7 @@ boot.kernelModules = mkBefore [ "kvm-intel" ]; <para> For other types of options, a merge may not be possible. For instance, if two modules define - <link xlink:href="options.html#opt-services.httpd.adminAddr"><literal>services.httpd.adminAddr</literal></link>, + <xref linkend="opt-services.httpd.adminAddr" />, <literal>nixos-rebuild</literal> will give an error: </para> <programlisting> @@ -89,11 +89,9 @@ services.httpd.adminAddr = pkgs.lib.mkForce "bob@example.org"; configuration value depends on itself. </para> </footnote> . For example, here is a module that adds some packages - to - <link xlink:href="options.html#opt-environment.systemPackages"><literal>environment.systemPackages</literal></link> - only if - <link xlink:href="options.html#opt-services.xserver.enable"><literal>services.xserver.enable</literal></link> - is set to <literal>true</literal> somewhere else: + to <xref linkend="opt-environment.systemPackages" /> only if + <xref linkend="opt-services.xserver.enable" /> is set to + <literal>true</literal> somewhere else: </para> <programlisting language="bash"> { config, pkgs, ... }: |