]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
Manual pages: order ENVIRONMENT / FILES / CONFORMING TO consistently
authorMichael Kerrisk (man-pages) <mtk.manpages@gmail.com>
Thu, 21 May 2020 07:28:49 +0000 (09:28 +0200)
committerKarel Zak <kzak@redhat.com>
Fri, 22 May 2020 08:25:52 +0000 (10:25 +0200)
There is value in ensuring that manual page sections use consistently
named sections, as far as possible, and also that sections have a
consistent order within manual pages. This is one of a series of patches
to place manual page sections in a consistent order.

In this patch, we ensure that the ENVIRONMENT, FILES, and CONFORMING TO
sections are always placed toward the end of the page, just above NOTES.

One page is not fixed by this patch: term-utils/agetty.8. This page
is a mess of unusual section names, and probably requires an individual
edit.

Testing that no gross editing mistake (causing accidental loss or addition
of text) was performed as follows:

    $ cat $(grep '\.SH' -l $(find . -name '*.[1-9]') |sort) | sort > a
    [Apply patch]
    $ cat $(grep '\.SH' -l $(find . -name '*.[1-9]') |sort) | sort > b
    $ diff a b
    $ echo $?
    0

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
disk-utils/fsck.8
lib/terminal-colors.d.5
sys-utils/losetup.8
sys-utils/mount.8
sys-utils/umount.8

index 012c51f6e5ba42810b2f3b1b8f848e2ae17851d2..97eb8d8c458f87ed5b22719c6305f92ceb14216d 100644 (file)
@@ -343,8 +343,6 @@ You're almost certainly doing something that you shouldn't be doing
 with
 .BR fsck .
 Options to different filesystem-specific fsck's are not standardized.
-.SH FILES
-.I /etc/fstab
 .SH ENVIRONMENT
 The
 .B fsck
@@ -388,6 +386,8 @@ enables libblkid debug output.
 .TP
 .B LIBMOUNT_DEBUG=all
 enables libmount debug output.
+.SH FILES
+.I /etc/fstab
 .SH AUTHORS
 .nf
 Theodore Ts'o <tytso@mit.edu>
index 4714bf505d24a124baf38fdbd9826015bf01c96b..b1be822f6bd44b606e8f8c1b37aa36ee23abe507 100644 (file)
@@ -145,6 +145,10 @@ Lines where the first non-blank character is a # (hash) are ignored.
 Any other use of the hash character is not interpreted as introducing
 a comment.
 
+.SH ENVIRONMENT
+.IP TERMINAL_COLORS_DEBUG=all
+enables debug output.
+
 .SH FILES
 .I $XDG_CONFIG_HOME/terminal-colors.d
 .br
@@ -152,10 +156,6 @@ a comment.
 .br
 .I /etc/terminal-colors.d
 
-.SH ENVIRONMENT
-.IP TERMINAL_COLORS_DEBUG=all
-enables debug output.
-
 .SH EXAMPLE
 Disable colors for all compatible utilities:
 .RS
index 0db7104490f52e41359d7e9b68959f0693eca43e..7b51921a940a8e7362db55b6773a3a088499dfc1 100644 (file)
@@ -178,6 +178,10 @@ displays the status of a loop device, it returns 1 if the device
 is not configured and 2 if an error occurred which prevented
 determining the status of the device.
 
+.SH ENVIRONMENT
+.IP LOOPDEV_DEBUG=all
+enables debug output.
+
 .SH FILES
 .TP
 .I /dev/loop[0..N]
@@ -185,10 +189,6 @@ loop block devices
 .TP
 .I /dev/loop-control
 loop control device
-
-.SH ENVIRONMENT
-.IP LOOPDEV_DEBUG=all
-enables debug output.
 .SH EXAMPLE
 The following commands can be used as an example of using the loop device.
 .nf
index 9a43672c67cecb2a4485d0181ecaac7cec13c377..81bc225cb519b185621e5f3121b2d99a6029eefc 100644 (file)
@@ -2574,6 +2574,17 @@ and
 to the mount.<suffix> helpers.  All other options are used in a
 comma-separated list as argument to the \fB\-o\fR option.
 
+.SH ENVIRONMENT
+.IP LIBMOUNT_FSTAB=<path>
+overrides the default location of the fstab file (ignored for suid)
+.IP LIBMOUNT_MTAB=<path>
+overrides the default location of the mtab file (ignored for suid)
+.IP LIBMOUNT_DEBUG=all
+enables libmount debug output
+.IP LIBBLKID_DEBUG=all
+enables libblkid debug output
+.IP LOOPDEV_DEBUG=all
+enables loop device setup debug output
 .SH FILES
 See also "\fBThe files /etc/fstab, /etc/mtab and /proc/mounts\fR" section above.
 .TP 18n
@@ -2594,17 +2605,6 @@ temporary file (unused on systems with mtab symlink)
 .TP
 .I /etc/filesystems
 a list of filesystem types to try
-.SH ENVIRONMENT
-.IP LIBMOUNT_FSTAB=<path>
-overrides the default location of the fstab file (ignored for suid)
-.IP LIBMOUNT_MTAB=<path>
-overrides the default location of the mtab file (ignored for suid)
-.IP LIBMOUNT_DEBUG=all
-enables libmount debug output
-.IP LIBBLKID_DEBUG=all
-enables libblkid debug output
-.IP LOOPDEV_DEBUG=all
-enables loop device setup debug output
 .SH HISTORY
 A
 .B mount
index 434877afc1a7519dfb74a534f8c4fdcfd9d5b33a..43363b11cbbfd0f25276a9f32fc14f7a3d856e6b 100644 (file)
@@ -253,6 +253,13 @@ to the \fB/sbin/umount.\fItype\fR helper independently of UID.
 .PP
 Note that \fI/etc/mtab\fR is currently deprecated and helper= and another
 userspace mount options are maintained by libmount.
+.SH ENVIRONMENT
+.IP LIBMOUNT_FSTAB=<path>
+overrides the default location of the fstab file (ignored for suid)
+.IP LIBMOUNT_MTAB=<path>
+overrides the default location of the mtab file (ignored for suid)
+.IP LIBMOUNT_DEBUG=all
+enables libmount debug output
 .SH FILES
 .TP
 .I /etc/mtab
@@ -264,13 +271,6 @@ table of known filesystems
 .TP
 .I /proc/self/mountinfo
 table of mounted filesystems generated by kernel.
-.SH ENVIRONMENT
-.IP LIBMOUNT_FSTAB=<path>
-overrides the default location of the fstab file (ignored for suid)
-.IP LIBMOUNT_MTAB=<path>
-overrides the default location of the mtab file (ignored for suid)
-.IP LIBMOUNT_DEBUG=all
-enables libmount debug output
 .SH HISTORY
 A
 .B umount