<para>
See the following list:
<randomList>
<listItem><para>A</para></listItem>
<listItem><para>B</para></listItem>
<listItem><para>C</para></listItem>
</randomList>
</para>
$ cat test1.xml
<para>
See the following list:
<randomList>
<listItem><para>A</para></listItem>
<listItem><para>B</para></listItem>
<listItem><para>C</para></listitem>
</randomList>
</para>
$ xml-format -I test1.xml
<para>
See the following list:
<randomList>
<listItem>
<para>A</para>
</listItem>
<listItem>
<para>B</para>
</listItem>
<listItem>
<para>C</para>
</listItem>
</randomList>
</para>
Using the -c (--compact) option:
$ xml-format test.xml
<section><title>Example</title><para><emphasis>A</emphasis> <emphasis
>B</emphasis> C</para><empty> </empty><p xml:space="preserve"><b>A
</b> <b>B</b> <b>C</b></p><para>
See the following list:
<randomList>
<listItem><para>A</para></listItem>
<listItem><para>B</para></listItem>
<listItem><para>C</para></listItem>
</randomList>
</para></section>
Using the -c (--compact) and -I (--indent-all) options together:
$ xml-format -cI test.xml
<section><title>Example</title><para><emphasis>A</emphasis> <emphasis
>B</emphasis> C</para><empty> </empty><p xml:space="preserve"><b>A
</b> <b>B</b> <b>C</b></p><para>
See the following list:
<randomList><listItem><para>A</para></listItem><listItem><para>B<
/para></listItem><listItem><para>C</para></listItem></randomList>
</para></section>