diff mbox series

[v3,2/4] docs: use the wks lexer for the kickstart examples

Message ID 20261127120528.837051-3-twoerner@gmail.com
State New
Headers show
Series sphinx: add lexers for wic kickstart files and pydevshell sessions | expand

Commit Message

Trevor Woerner Nov. 27, 2026, 12:05 p.m. UTC
The wic kickstart examples in the manuals are tagged shell or text, or
left to the default language. Tag them wks so their statements and
options are highlighted as kickstart.

AI-Generated: codex/claude-opus 5.5 (xhigh)
Signed-off-by: Trevor Woerner <twoerner@gmail.com>
---
changes in v3:
- new: tag the kickstart examples wks, as asked in review
---
 documentation/dev-manual/wic.rst       |  6 +++---
 documentation/ref-manual/kickstart.rst | 16 ++++++++++------
 documentation/ref-manual/variables.rst |  8 ++++++--
 3 files changed, 19 insertions(+), 11 deletions(-)
diff mbox series

Patch

diff --git a/documentation/dev-manual/wic.rst b/documentation/dev-manual/wic.rst
index 85160bbdf1a0..07e165abeb11 100644
--- a/documentation/dev-manual/wic.rst
+++ b/documentation/dev-manual/wic.rst
@@ -343,7 +343,7 @@  Mode that uses the ``directdisk`` file:
 Here are the actual partition language commands used in the
 ``genericx86.wks`` file to generate an image:
 
-.. code-block:: shell
+.. code-block:: wks
 
    # short-description: Create an EFI disk image for genericx86*
    # long-description: Creates a partitioned EFI disk image for genericx86* machines
@@ -403,7 +403,7 @@  implementation, it looks for the plugin with the same name as the
 partition. For example, if the partition is set up using the following
 command in a kickstart file:
 
-.. code-block:: shell
+.. code-block:: wks
 
    part /boot --source bootimg_pcbios --ondisk sda --label boot --active --align 1024
 
@@ -598,7 +598,7 @@  changes all instances of "``--ondisk sda``" to "``--ondisk sdb``". The
 example changes the following two lines and leaves the remaining lines
 untouched:
 
-.. code-block:: shell
+.. code-block:: wks
 
    part /boot --source bootimg_pcbios --ondisk sdb --label boot --active --align 1024
    part / --source rootfs --ondisk sdb --fstype=ext4 --label platform --align 1024 --use-uuid
diff --git a/documentation/ref-manual/kickstart.rst b/documentation/ref-manual/kickstart.rst
index 8d5e9f317b06..c2b7d6aa1102 100644
--- a/documentation/ref-manual/kickstart.rst
+++ b/documentation/ref-manual/kickstart.rst
@@ -57,7 +57,9 @@  Command: part
 -------------
 
 This command creates a partition on the system and uses the
-following syntax::
+following syntax:
+
+.. code-block:: wks
 
    part [mntpoint]
 
@@ -85,7 +87,9 @@  must also provide one of the ``--ondrive``, ``--ondisk``, or
    be disabled in custom configurations.
 
 Here is an example that uses "/" as the mountpoint. The command uses
-``--ondisk`` to force the partition onto the ``sdb`` disk::
+``--ondisk`` to force the partition onto the ``sdb`` disk:
+
+.. code-block:: wks
 
       part / --source rootfs --ondisk sdb --fstype=ext3 --label platform --align 1024
 
@@ -275,7 +279,7 @@  The ``include`` directive can be used to include a WKS file into another. The
 only argument to this command is the path to the file to include, relative to
 the current file. For example:
 
-.. code-block:: shell
+.. code-block:: wks
 
    include common.wks.inc
 
@@ -298,7 +302,7 @@  variable expansion mechanism:
    :term:`wic` command-line utility, not :term:`BitBake`. However, the syntax to
    reference these variables is the same. For example:
 
-   .. code-block:: text
+   .. code-block:: wks
       :caption: Snippet from ``mkefidisk.wks``
 
       bootloader --ptable gpt --timeout=5 --append="rootfstype=ext4 console=${KERNEL_CONSOLE} console=tty0"
@@ -321,7 +325,7 @@  variable expansion mechanism:
    This means that the :term:`WICVARS` list has no effect anymore: those
    variables are expanded by :term:`BitBake` directly. For example:
 
-   .. code-block:: text
+   .. code-block:: wks
       :caption: Snippet from ``efi-uki-bootdisk.wks.in``
 
       part /boot --source bootimg_efi --sourceparams="loader=${EFI_PROVIDER}" --label boot --active ...
@@ -331,7 +335,7 @@  variable expansion mechanism:
    This also means that ``.wks.in`` files can contain inline Python expressions.
    Here is a made up example:
 
-   .. code-block:: text
+   .. code-block:: wks
 
       part / --source rootfs --fstype=ext4 --label root --align ${@4 * 1024} --size 5G
 
diff --git a/documentation/ref-manual/variables.rst b/documentation/ref-manual/variables.rst
index 2e01d04228ce..15ff5be2380a 100644
--- a/documentation/ref-manual/variables.rst
+++ b/documentation/ref-manual/variables.rst
@@ -4318,7 +4318,9 @@  system and gives an overview of their function and contents.
 
       You can also specify the target by label, UUID or partition name if multiple
       extra partitions coexist. Let's take the following example. This would be
-      the WKS file for the image currently being built::
+      the WKS file for the image currently being built:
+
+      .. code-block:: wks
 
          part --source extra_partition --fstype=ext4 --label foo
          part --source extra_partition --fstype=ext4 --uuid e7d0824e-cda3-4bed-9f54-9ef5312d105d
@@ -12173,7 +12175,9 @@  system and gives an overview of their function and contents.
       The resulting binary can be flashed using :doc:`WIC </dev-manual/wic>` or
       any other flashing method at the environment offset, overriding any
       existing environment if one is present. Below is an example of a WKS file
-      to flash the binary::
+      to flash the binary:
+
+      .. code-block:: wks
 
          part --source rawcopy --sourceparams="file=u-boot-initial-env-sd.bin" --ondisk sda --no-table --offset 4096k