1
0
mirror of https://github.com/systemd/systemd.git synced 2024-12-22 17:35:35 +03:00

systemctl: add --clean= values to documentation and shell completion

This commit is contained in:
Luca Boccassi 2024-04-08 02:20:18 +01:00 committed by Luca Boccassi
parent 18d2641236
commit ef5f7f9437
3 changed files with 52 additions and 3 deletions

View File

@ -575,8 +575,6 @@ node /org/freedesktop/systemd1 {
<!--method EnqueueUnitJob is not documented!-->
<!--method CleanUnit is not documented!-->
<!--method FreezeUnit is not documented!-->
<!--method ThawUnit is not documented!-->
@ -1585,6 +1583,12 @@ node /org/freedesktop/systemd1 {
shouldn't be bound to a lifecycle of the service, e.g. they should continue running after the restart
of the service. Note that the main PID of the service can not be migrated to an auxiliary scope.
Also, <varname>flags</varname> argument must be 0 and is reserved for future extensions.</para>
<para><function>CleanUnit()</function> deletes the configuration, state, logs, cache and runtime data
directories and clear out the file descriptors store for the unit, as specified in the mask
parameters. The possible values are <literal>configuration</literal>, <literal>state</literal>,
<literal>logs</literal>, <literal>cache</literal>, <literal>runtime</literal>,
<literal>fdstore</literal>, and <literal>all</literal>.</para>
</refsect2>
<refsect2>

View File

@ -569,6 +569,51 @@ Jan 12 10:46:45 example.com bluetoothd[8900]: gatt-time-server: Input/output err
these three types of resources are generally redundant and reproducible on the next invocation of
the unit). Note that the specified units must be stopped to invoke this operation.</para>
<table>
<title>
Possible values for <option>--what=</option>
</title>
<tgroup cols='2'>
<thead>
<row>
<entry>Value</entry>
<entry>Unit Setting</entry>
</row>
</thead>
<tbody>
<row>
<entry><literal>runtime</literal></entry>
<entry><varname>RuntimeDirectory=</varname></entry>
</row>
<row>
<entry><literal>state</literal></entry>
<entry><varname>StateDirectory=</varname></entry>
</row>
<row>
<entry><literal>cache</literal></entry>
<entry><varname>CacheDirectory=</varname></entry>
</row>
<row>
<entry><literal>logs</literal></entry>
<entry><varname>LogsDirectory=</varname></entry>
</row>
<row>
<entry><literal>configuration</literal></entry>
<entry><varname>ConfigurationDirectory=</varname></entry>
</row>
<row>
<entry><literal>fdstore</literal></entry>
<entry><varname>FileDescriptorStorePreserve=</varname></entry>
</row>
<row>
<entry><literal>all</literal></entry>
<entry>All of the above</entry>
</row>
</tbody>
</tgroup>
</table>
<xi:include href="version-info.xml" xpointer="v243"/>
</listitem>
</varlistentry>

View File

@ -193,7 +193,7 @@ _systemctl () {
comps='auto yes no'
;;
--what)
comps='configuration state cache logs runtime all'
comps='configuration state cache logs runtime fdstore all'
;;
--image)
comps=$(compgen -A file -- "$cur")