[Pkg-alsa-devel] Bug#1088311: aconnect.1: Some remarks and editorial changes for this man page

Bjarni Ingi Gislason bjarniig at simnet.is
Tue Nov 26 20:36:09 GMT 2024


Package: alsa-utils
Version: 1.2.12-1
Severity: minor
Tags: patch

   * What led up to the situation?

     Checking for defects with

test-[g|n]roff -mandoc -t -K utf8 -rF0 -rHY=0 -ww -b -z < "man page"

  [Use "groff -e ' $' <file>" to find trailing spaces.]

  ["test-groff" is a script in the repository for "groff"; is not shipped]
(local copy and "troff" slightly changed by me).

  [The fate of "test-nroff" was decided in groff bug #55941.]

   * What was the outcome of this action?

troff: backtrace: '<stdin>':4: macro 'EX'
troff: backtrace: file '<stdin>':44
troff:<stdin>:44: warning: font name 'CW' is deprecated
troff: backtrace: file '<stdin>':106
troff:<stdin>:106: warning: trailing space in the line

   * What outcome did you expect instead?

     No output (no warnings).

-.-

  General remarks and further material, if a diff-file exist, are in the
attachments.


-- System Information:
Debian Release: trixie/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 6.11.9-amd64 (SMP w/2 CPU threads; PREEMPT)
Locale: LANG=is_IS.iso88591, LC_CTYPE=is_IS.iso88591 (charmap=ISO-8859-1), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: sysvinit (via /sbin/init)

Versions of packages alsa-utils depends on:
ii  kmod              33+20240816-2
ii  libasound2t64     1.2.12-1+b1
ii  libatopology2t64  1.2.12-1+b1
ii  libc6             2.40-3
ii  libfftw3-single3  3.3.10-1+b3
ii  libncursesw6      6.5-2+b1
ii  libsamplerate0    0.2.2-4+b2
ii  libtinfo6         6.5-2+b1

alsa-utils recommends no packages.

Versions of packages alsa-utils suggests:
pn  dialog  <none>

-- no debconf information
-------------- next part --------------
Input file is aconnect.1

  Any program (person), that produces man pages, should check the output
for defects by using (both groff and nroff)

[gn]roff -mandoc -t -ww -b -z -K utf8  <man page>

  The same goes for man pages that are used as an input.

  For a style guide use

  mandoc -T lint

-.-

  So any 'generator' should check its products with the above mentioned
'groff', 'mandoc',  and additionally with 'nroff ...'.

  This is just a simple quality control measure.

  The 'generator' may have to be corrected to get a better man page,
the source file may, and any additional file may.

  Common defects:

  Input text line longer than 80 bytes.

  Not removing trailing spaces (in in- and output).
  The reason for these trailing spaces should be found and eliminated.

  Not beginning each input sentence on a new line.
Lines should thus be shorter.

  See man-pages(7), item 'semantic newline'.

-.-

The difference between the formatted output of the original and patched file
can be seen with:

  nroff -mandoc <file1> > <out1>
  nroff -mandoc <file2> > <out2>
  diff -u <out1> <out2>

and for groff, using

"printf '%s\n%s\n' '.kern 0' '.ss 12 0' | groff -mandoc -Z - "

instead of 'nroff -mandoc'

  Add the option '-t', if the file contains a table.

  Read the output of 'diff -u' with 'less -R' or similar.

-.-.

  If 'man' (man-db) is used to check the manual for warnings,
the following must be set:

  The option "-warnings=w"

  The environmental variable:

export MAN_KEEP_STDERR=yes (or any non-empty value)

  or

  (produce only warnings):

export MANROFFOPT="-ww -b -z"

export MAN_KEEP_STDERR=yes (or any non-empty value)


-.-.

Output from "mandoc -T lint  aconnect.1 ": (shortened list)

      1 whitespace at end of input line

-.-.

Output from "test-groff -mandoc -t -ww -b -z aconnect.1 ": (shortened list)

      1 font name 'CW' is deprecated
      1 trailing space in the line

-.-.

Output from "mandoc -T lint  aconnect.1 ":

mandoc: aconnect.1:106:12: STYLE: whitespace at end of input line

-.-.

Remove space characters at the end of lines.

Use "git apply ... --whitespace=fix" to fix extra space issues, or use
global configuration "core.whitespace".

106:option, but 

-.-.

Add a comma (or \&) after "e.g." and "i.e.", or use English words
(man-pages(7)).
Abbreviation points should be protected against being interpreted as
an end of sentence, if they are not, and that independent of the
current place on the line.

37:is redirected to the receiver port (65:0).  When another port (e.g. 65:1)

-.-.

Wrong distance between sentences in the input file.

  Separate the sentences and subordinate clauses; each begins on a new
line.  See man-pages(7) ("Conventions for source file layout") and
"info groff" ("Input Conventions").

  The best procedure is to always start a new sentence on a new line,
at least, if you are typing on a computer.

Remember coding: Only one command ("sentence") on each (logical) line.

E-mail: Easier to quote exactly the relevant lines.

Generally: Easier to edit the sentence.

Patches: Less unaffected text.

Search for two adjacent words is easier, when they belong to the same line,
and the same phrase.

  The amount of space between sentences in the output can then be
controlled with the ".ss" request.

37:is redirected to the receiver port (65:0).  When another port (e.g. 65:1)

-.-.

The section part for a manual page is set in roman font.

29:.B aseqview(1),

-.-.

Split a punctuation from a single argument, if a two-font macro is meant

29:.B aseqview(1),
31:.B aconnect.
116:.B \-o.
121:.B \-i.

-.-.

Name of a manual is set in bold, the section in roman.
See man-pages(7).

145:aseqnet(1), aseqview(1)

-.-.

Put a parenthetical sentence, phrase on a separate line,
if not part of a code.
See man-pages(7), item "semantic newline".

aconnect.1:101:the receiver port must use (not necessarily own) the specified queue.

-.-.

Two or more space charaters between printable characters.

When the distance is between sentences,
start the beginning of the second one on a separate line
("semantic newline").

37:is redirected to the receiver port (65:0).  When another port (e.g. 65:1)
82:option.  This function is useful for terminating the ALSA drivers,
127:List the current connection status.  The connected and connecting ports

-.-.

Output from "test-groff  -mandoc -t -K utf8 -rF0 -rHY=0 -ww -b -z ":

troff: backtrace: '<stdin>':4: macro 'EX'
troff: backtrace: file '<stdin>':44
troff:<stdin>:44: warning: font name 'CW' is deprecated
troff: backtrace: file '<stdin>':106
troff:<stdin>:106: warning: trailing space in the line

-.-

  In the EX macro, use the CR font if the formatter is "groff" or compatible.

-------------- next part --------------
--- aconnect.1	2024-11-26 17:53:12.911444679 +0000
+++ aconnect.1.new	2024-11-26 18:29:53.459787100 +0000
@@ -1,7 +1,8 @@
 .TH aconnect 1 "August 31, 2000"
 .de EX
 .nf
-.ft CW
+.ie \\n(.g .ft CR
+.el .ft CW
 ..
 .de EE
 .ft R
@@ -26,17 +27,19 @@ is a utility to connect and disconnect t
 system.
 The ports with the arbitrary subscription permission, such as created
 by
-.B aseqview(1),
+.BR aseqview (1),
 can be connected to any (MIDI) device ports using
-.B aconnect.
+.BR aconnect .
 For example, to connect from port 64:0 to 65:0, run as follows:
 .IP "" 4
 % aconnect 64:0 65:0
 .PP
-The connection is one-way, and the whole data to the sender port (64:0)
-is redirected to the receiver port (65:0).  When another port (e.g. 65:1)
-is attached to the same sender port, the data is sent to both receiver
-ports.
+The connection is one-way,
+and the whole data to the sender port (64:0)
+is redirected to the receiver port (65:0).
+When another port (e.g., 65:1)
+is attached to the same sender port,
+the data is sent to both receiver ports.
 For disconnection, use
 .B \-d
 option.
@@ -86,44 +89,46 @@ unless their connections are removed.
 .SH OPTIONS
 .SS CONNECTION MANAGEMENT
 .TP
-.B \-d, \-\-disconnect
+.BR \-d ", " \-\-disconnect
 Disconnect the given subscription.
 .TP
-.B \-e, \-\-exclusive
+.BR \-e ", "\-\-exclusive
 Connect ports with exclusive mode.
 Both sender and receiver ports can be no longer connected by any other ports.
 .TP
-.B \-r, \-\-real queue
+.BR \-r ", " \-\-real \fIqueue\fP
 Convert time-stamps of event packets to the current value of the given
 .I real-time
 queue.
-This is option is, however, not so useful, since
-the receiver port must use (not necessarily own) the specified queue.
+This option is, however, not so useful,
+since the receiver port must use
+(not necessarily own)
+the specified queue.
 .TP
-.B \-t, \-\-tick queue
+.BR \-t ", " \-\-tick \fIqueue\fP
 Like
 .B \-r
-option, but 
+option, but
 time-stamps are converted to the current value of the given
 .I tick
 queue.
 
 .SS LIST PORTS
 .TP
-.B \-i, \-\-input
+.BR \-i ", " \-\-input
 List existing input (readable) ports.
 This option is exclusive to
-.B \-o.
+.BR \-o .
 .TP
-.B \-o, \-\-output
+.BR  \-o ", " \-\-output
 List existing output (writable) ports.
 This option is exclusive to
-.B \-i.
+.BR \-i .
 .TP
-.B \-a, \-\-all
+.BR \-a ", " \-\-all
 List inactive ports, too.
 .TP
-.B \-l, \-\-list
+.BR \-l ", " \-\-list
 List the current connection status.  The connected and connecting ports
 from/to each port are listed together.
 The suffix flag
@@ -138,11 +143,11 @@ queue, respectively.
 
 .SS REMOVE ALL CONNECTIONS
 .TP
-.B \-x, \-\-removeall
+.BR \-x ", " \-\-removeall
 Remove all exported connections.
 
 .SH "SEE ALSO"
-aseqnet(1), aseqview(1)
+.BR aseqnet "(1), " aseqview (1)
 
 .SH AUTHOR
 Takashi Iwai <tiwai at suse.de>


More information about the Pkg-alsa-devel mailing list