]> git.ipfire.org Git - thirdparty/systemd.git/blob - man/less-variables.xml
Merge pull request #16678 from poettering/loop-configure
[thirdparty/systemd.git] / man / less-variables.xml
1 <?xml version="1.0"?>
2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
4 <!-- SPDX-License-Identifier: LGPL-2.1+ -->
5
6 <refsect1>
7 <title>Environment</title>
8
9 <variablelist class='environment-variables'>
10 <varlistentry id='pager'>
11 <term><varname>$SYSTEMD_PAGER</varname></term>
12
13 <listitem><para>Pager to use when <option>--no-pager</option> is not given; overrides
14 <varname>$PAGER</varname>. If neither <varname>$SYSTEMD_PAGER</varname> nor <varname>$PAGER</varname> are set, a
15 set of well-known pager implementations are tried in turn, including
16 <citerefentry project='man-pages'><refentrytitle>less</refentrytitle><manvolnum>1</manvolnum></citerefentry> and
17 <citerefentry project='man-pages'><refentrytitle>more</refentrytitle><manvolnum>1</manvolnum></citerefentry>, until one is found. If
18 no pager implementation is discovered no pager is invoked. Setting this environment variable to an empty string
19 or the value <literal>cat</literal> is equivalent to passing <option>--no-pager</option>.</para></listitem>
20 </varlistentry>
21
22 <varlistentry id='less'>
23 <term><varname>$SYSTEMD_LESS</varname></term>
24
25 <listitem><para>Override the options passed to <command>less</command> (by default
26 <literal>FRSXMK</literal>).</para>
27
28 <para>Users might want to change two options in particular:</para>
29
30 <variablelist>
31 <varlistentry>
32 <term><option>K</option></term>
33
34 <para>This option instructs the pager to exit immediately when
35 <keycombo><keycap>Ctrl</keycap><keycap>C</keycap></keycombo> is pressed. To allow
36 <command>less</command> to handle <keycombo><keycap>Ctrl</keycap><keycap>C</keycap></keycombo>
37 itself to switch back to the pager command prompt, unset this option.</para>
38
39 <para>If the value of <varname>$SYSTEMD_LESS</varname> does not include <literal>K</literal>,
40 and the pager that is invoked is <command>less</command>,
41 <keycombo><keycap>Ctrl</keycap><keycap>C</keycap></keycombo> will be ignored by the
42 executable, and needs to be handled by the pager.</para>
43 </varlistentry>
44
45 <varlistentry>
46 <term><option>X</option></term>
47
48 <para>This option instructs the pager to not send termcap initialization and deinitialization
49 strings to the terminal. It is set by default to allow command output to remain visible in the
50 terminal even after the pager exits. Nevertheless, this prevents some pager functionality from
51 working, in particular paged output cannot be scrolled with the mouse.</para>
52 </varlistentry>
53 </variablelist>
54
55 <para>See
56 <citerefentry project='man-pages'><refentrytitle>less</refentrytitle><manvolnum>1</manvolnum></citerefentry>
57 for more discussion.</para></listitem>
58 </varlistentry>
59
60 <varlistentry id='lesscharset'>
61 <term><varname>$SYSTEMD_LESSCHARSET</varname></term>
62
63 <listitem><para>Override the charset passed to <command>less</command> (by default <literal>utf-8</literal>, if
64 the invoking terminal is determined to be UTF-8 compatible).</para></listitem>
65 </varlistentry>
66
67 <varlistentry id='colors'>
68 <term><varname>$SYSTEMD_COLORS</varname></term>
69
70 <listitem><para>The value must be a boolean. Controls whether colorized output should be
71 generated. This can be specified to override the decision that <command>systemd</command> makes based
72 on <varname>$TERM</varname> and what the console is connected to.</para>
73 </listitem>
74 </varlistentry>
75
76 <!-- This is not documented on purpose, because it is not clear if $NO_COLOR will become supported
77 widely enough. So let's provide support, but without advertising this.
78 <varlistentry id='no-color'>
79 <term><varname>$NO_COLOR</varname></term>
80
81 <listitem><para>If set (to any value), and <varname>$SYSTEMD_COLORS</varname> is not set, equivalent to
82 <option>SYSTEMD_COLORS=0</option>. See <ulink url="https://no-color.org/">no-color.org</ulink>.</para>
83 </listitem>
84 </varlistentry>
85 -->
86
87 <varlistentry id='urlify'>
88 <term><varname>$SYSTEMD_URLIFY</varname></term>
89
90 <listitem><para>The value must be a boolean. Controls whether clickable links should be generated in
91 the output for terminal emulators supporting this. This can be specified to override the decision that
92 <command>systemd</command> makes based on <varname>$TERM</varname> and other conditions.</para>
93 </listitem>
94 </varlistentry>
95
96 </variablelist>
97 </refsect1>