summaryrefslogtreecommitdiffstats
path: root/man/kernel-install.xml
diff options
context:
space:
mode:
authorDaan De Meyer <daan.j.demeyer@gmail.com>2023-10-23 11:18:35 +0200
committerDaan De Meyer <daan.j.demeyer@gmail.com>2023-11-06 14:43:09 +0100
commitbdd36c003d9c4c4ca89c92be504615378f61513c (patch)
tree071f201dec21e3b7a34ee5ed87e5da67c3dbcd02 /man/kernel-install.xml
parentboot-entry: Add boot_entry_token_type_to_string() (diff)
downloadsystemd-bdd36c003d9c4c4ca89c92be504615378f61513c.tar.xz
systemd-bdd36c003d9c4c4ca89c92be504615378f61513c.zip
kernel-install: Add --json option for inspect verb
In mkosi, we can't use kernel-install directly but we do want to mimick its behavior as much as possible. Let's make that easier by making it easy to fetch data from kernel-install as JSON. To get all the necessary data, we extend the inspect verb to also allow passing in a kernel version and initrds, to mimick the "add" verb. The kernel version is used to determine the "Entry Directory", and in absence of auto-detection of kernel version in kernel-install we have to allow users to pass it. We also add --no-pager while we're at it.
Diffstat (limited to 'man/kernel-install.xml')
-rw-r--r--man/kernel-install.xml11
1 files changed, 9 insertions, 2 deletions
diff --git a/man/kernel-install.xml b/man/kernel-install.xml
index 64137ce61c..822c289259 100644
--- a/man/kernel-install.xml
+++ b/man/kernel-install.xml
@@ -40,7 +40,9 @@
<command>kernel-install</command>
<arg choice="opt" rep="repeat">OPTIONS</arg>
<arg choice="plain">inspect</arg>
+ <arg choice="opt"><replaceable>KERNEL-VERSION</replaceable></arg>
<arg choice="opt"><replaceable>KERNEL-IMAGE</replaceable></arg>
+ <arg choice="opt" rep="repeat"><replaceable>INITRD-FILE</replaceable></arg>
</cmdsynopsis>
</refsynopsisdiv>
@@ -176,11 +178,14 @@
</listitem>
</varlistentry>
<varlistentry>
- <term><command>inspect [<replaceable>KERNEL-IMAGE</replaceable>]</command></term>
+ <term>
+ <command>inspect [[<replaceable>KERNEL-VERSION</replaceable>] <replaceable>KERNEL-IMAGE</replaceable>] [<replaceable>INITRD-FILE</replaceable> ...]</command>
+ </term>
<listitem>
<para>Shows the various paths and parameters configured or auto-detected. In particular shows the
values of the various <varname>$KERNEL_INSTALL_*</varname> environment variables listed
- below.</para>
+ below. The <option>--json</option> option can be used to get the output of this verb as a JSON
+ object.</para>
<xi:include href="version-info.xml" xpointer="v251"/>
</listitem>
@@ -298,6 +303,8 @@
<xi:include href="standard-options.xml" xpointer="help" />
<xi:include href="standard-options.xml" xpointer="version" />
+ <xi:include href="standard-options.xml" xpointer="no-pager"/>
+ <xi:include href="standard-options.xml" xpointer="json" />
</variablelist>
</refsect1>