Skip to content

Commit 971a1f8

Browse files
committed
sort(1): use .Dl for one-liners
1 parent 2daad96 commit 971a1f8

1 file changed

Lines changed: 14 additions & 19 deletions

File tree

usr.bin/sort/sort.1

Lines changed: 14 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
.\" $NetBSD: sort.1,v 1.43 2026/01/17 19:08:03 jkoshy Exp $
1+
.\" $NetBSD: sort.1,v 1.44 2026/01/17 19:29:44 uwe Exp $
22
.\"
33
.\" Copyright (c) 2000-2003 The NetBSD Foundation, Inc.
44
.\" All rights reserved.
@@ -452,41 +452,36 @@ and
452452
.Sh EXAMPLES
453453
To silently check if the lines in a file are sorted lexicographically,
454454
use:
455-
.Bd -literal -offset indent
456-
$ sort -C file
457-
.Ed
455+
.Pp
456+
.Dl $ sort -C file
458457
.Pp
459458
To merge three pre-sorted files and write the merged result to stdout,
460459
use:
461-
.Bd -literal -offset indent
462-
$ sort -m file1 file2 file3
463-
.Ed
460+
.Pp
461+
.Dl $ sort -m file1 file2 file3
464462
.Pp
465463
To sort the lines in a file lexicographically using the second
466464
whitespace-separated field of each line as the sort key preserving any
467465
leading whitespace in the sort key, use:
468-
.Bd -literal -offset indent
469-
$ sort -k 2 file
470-
.Ed
466+
.Pp
467+
.Dl $ sort -k 2 file
471468
.Pp
472469
To sort the lines in a file lexicographically using the second
473470
whitespace-separated field on each line as the sort key ignoring any
474471
leading whitespace in the sort key, use:
475-
.Bd -literal -offset indent
476-
$ sort -k 2b file
477-
.Ed
472+
.Pp
473+
.Dl $ sort -k 2b file
478474
.Pp
479475
To sort the lines in a file numerically using the second
480476
whitespace-separated field on each line as the sort key, starting the
481477
sort key at the second non-blank character within the field, use:
482-
.Bd -literal -offset indent
483-
$ sort -k 2.2nb file
484-
.Ed
478+
.Pp
479+
.Dl $ sort -k 2.2nb file
485480
.Pp
486481
To lexicographically sort the lines of a file in reverse order, use:
487-
.Bd -literal -offset indent
488-
$ sort -r -f file
489-
.Ed
482+
.Pp
483+
.Dl $ sort -r -f file
484+
.
490485
.Sh EXIT STATUS
491486
Sort exits with one of the following values:
492487
.Bl -tag -width flag -compact

0 commit comments

Comments
 (0)