about summary refs log tree commit diff
path: root/nixos/doc/manual/man-nixos-generate-config.xml
diff options
context:
space:
mode:
Diffstat (limited to 'nixos/doc/manual/man-nixos-generate-config.xml')
-rw-r--r--nixos/doc/manual/man-nixos-generate-config.xml64
1 files changed, 15 insertions, 49 deletions
diff --git a/nixos/doc/manual/man-nixos-generate-config.xml b/nixos/doc/manual/man-nixos-generate-config.xml
index 61531a8f01ca..3ebfd50f036d 100644
--- a/nixos/doc/manual/man-nixos-generate-config.xml
+++ b/nixos/doc/manual/man-nixos-generate-config.xml
@@ -13,18 +13,18 @@
  </refnamediv>
  <refsynopsisdiv>
   <cmdsynopsis>
-   <command>nixos-generate-config</command>
+   <command>nixos-generate-config</command> 
    <arg>
     <option>--force</option>
    </arg>
-
+    
    <arg>
     <arg choice='plain'>
      <option>--root</option>
     </arg>
      <replaceable>root</replaceable>
    </arg>
-
+    
    <arg>
     <arg choice='plain'>
      <option>--dir</option>
@@ -44,20 +44,10 @@
      </term>
      <listitem>
       <para>
-       This module sets NixOS configuration options based on your current
-       hardware configuration. In particular, it sets the
-       <option>fileSystem</option> option to reflect all currently mounted file
-       systems, the <option>swapDevices</option> option to reflect active swap
-       devices, and the <option>boot.initrd.*</option> options to ensure that
-       the initial ramdisk contains any kernel modules necessary for mounting
-       the root file system.
+       This module sets NixOS configuration options based on your current hardware configuration. In particular, it sets the <option>fileSystem</option> option to reflect all currently mounted file systems, the <option>swapDevices</option> option to reflect active swap devices, and the <option>boot.initrd.*</option> options to ensure that the initial ramdisk contains any kernel modules necessary for mounting the root file system.
       </para>
       <para>
-       If this file already exists, it is overwritten. Thus, you should not
-       modify it manually. Rather, you should include it from your
-       <filename>/etc/nixos/configuration.nix</filename>, and re-run
-       <command>nixos-generate-config</command> to update it whenever your
-       hardware configuration changes.
+       If this file already exists, it is overwritten. Thus, you should not modify it manually. Rather, you should include it from your <filename>/etc/nixos/configuration.nix</filename>, and re-run <command>nixos-generate-config</command> to update it whenever your hardware configuration changes.
       </para>
      </listitem>
     </varlistentry>
@@ -67,10 +57,7 @@
      </term>
      <listitem>
       <para>
-       This is the main NixOS system configuration module. If it already
-       exists, it’s left unchanged. Otherwise,
-       <command>nixos-generate-config</command> will write a template for you
-       to customise.
+       This is the main NixOS system configuration module. If it already exists, it’s left unchanged. Otherwise, <command>nixos-generate-config</command> will write a template for you to customise.
       </para>
      </listitem>
     </varlistentry>
@@ -89,12 +76,7 @@
     </term>
     <listitem>
      <para>
-      If this option is given, treat the directory
-      <replaceable>root</replaceable> as the root of the file system. This
-      means that configuration files will be written to
-      <filename><replaceable>root</replaceable>/etc/nixos</filename>, and that
-      any file systems outside of <replaceable>root</replaceable> are ignored
-      for the purpose of generating the <option>fileSystems</option> option.
+      If this option is given, treat the directory <replaceable>root</replaceable> as the root of the file system. This means that configuration files will be written to <filename><replaceable>root</replaceable>/etc/nixos</filename>, and that any file systems outside of <replaceable>root</replaceable> are ignored for the purpose of generating the <option>fileSystems</option> option.
      </para>
     </listitem>
    </varlistentry>
@@ -104,9 +86,7 @@
     </term>
     <listitem>
      <para>
-      If this option is given, write the configuration files to the directory
-      <replaceable>dir</replaceable> instead of
-      <filename>/etc/nixos</filename>.
+      If this option is given, write the configuration files to the directory <replaceable>dir</replaceable> instead of <filename>/etc/nixos</filename>.
      </para>
     </listitem>
    </varlistentry>
@@ -116,8 +96,7 @@
     </term>
     <listitem>
      <para>
-      Overwrite <filename>/etc/nixos/configuration.nix</filename> if it already
-      exists.
+      Overwrite <filename>/etc/nixos/configuration.nix</filename> if it already exists.
      </para>
     </listitem>
    </varlistentry>
@@ -127,8 +106,7 @@
     </term>
     <listitem>
      <para>
-      Omit everything concerning file systems and swap devices from the
-      hardware configuration.
+      Omit everything concerning file systems and swap devices from the hardware configuration.
      </para>
     </listitem>
    </varlistentry>
@@ -138,9 +116,7 @@
     </term>
     <listitem>
      <para>
-      Don't generate <filename>configuration.nix</filename> or
-      <filename>hardware-configuration.nix</filename> and print the hardware
-      configuration to stdout only.
+      Don't generate <filename>configuration.nix</filename> or <filename>hardware-configuration.nix</filename> and print the hardware configuration to stdout only.
      </para>
     </listitem>
    </varlistentry>
@@ -149,16 +125,11 @@
  <refsection>
   <title>Examples</title>
   <para>
-   This command is typically used during NixOS installation to write initial
-   configuration modules. For example, if you created and mounted the target
-   file systems on <filename>/mnt</filename> and
-   <filename>/mnt/boot</filename>, you would run:
+   This command is typically used during NixOS installation to write initial configuration modules. For example, if you created and mounted the target file systems on <filename>/mnt</filename> and <filename>/mnt/boot</filename>, you would run:
 <screen>
 <prompt>$ </prompt>nixos-generate-config --root /mnt
 </screen>
-   The resulting file
-   <filename>/mnt/etc/nixos/hardware-configuration.nix</filename> might look
-   like this:
+   The resulting file <filename>/mnt/etc/nixos/hardware-configuration.nix</filename> might look like this:
 <programlisting>
 # Do not modify this file!  It was generated by ‘nixos-generate-config’
 # and may be overwritten by future invocations.  Please make changes
@@ -193,10 +164,7 @@
   nix.maxJobs = 8;
 }
 </programlisting>
-   It will also create a basic
-   <filename>/mnt/etc/nixos/configuration.nix</filename>, which you should edit
-   to customise the logical configuration of your system. This file includes
-   the result of the hardware scan as follows:
+   It will also create a basic <filename>/mnt/etc/nixos/configuration.nix</filename>, which you should edit to customise the logical configuration of your system. This file includes the result of the hardware scan as follows:
 <programlisting>
   imports = [ ./hardware-configuration.nix ];
 </programlisting>
@@ -206,9 +174,7 @@
 <screen>
 <prompt>$ </prompt>nixos-generate-config
 </screen>
-   to update <filename>/etc/nixos/hardware-configuration.nix</filename>. Your
-   <filename>/etc/nixos/configuration.nix</filename> will
-   <emphasis>not</emphasis> be overwritten.
+   to update <filename>/etc/nixos/hardware-configuration.nix</filename>. Your <filename>/etc/nixos/configuration.nix</filename> will <emphasis>not</emphasis> be overwritten.
   </para>
  </refsection>
 </refentry>