Package: icu-devtools Version: 72.1-5+b1 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: file '<stdin>':119 troff:<stdin>:119: warning: trailing space in the line troff: backtrace: file '<stdin>':171 troff:<stdin>:171: warning: trailing space in the line troff: backtrace: file '<stdin>':173 troff:<stdin>:173: 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.5-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 icu-devtools depends on: ii libc6 2.40-3 ii libgcc-s1 14.2.0-8 ii libicu72 72.1-5+b1 ii libstdc++6 14.2.0-8 icu-devtools recommends no packages. icu-devtools suggests no packages. -- no debconf information
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 icupkg.8": (possibly shortened list) mandoc: icupkg.8:119:59: STYLE: whitespace at end of input line mandoc: icupkg.8:171:53: STYLE: whitespace at end of input line mandoc: icupkg.8:173:24: 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". 119:in the resulting data instead of the ICU copyright notice. 171:Items for removal or extraction may contain a single 173:wildcard character. The -.-. Use the correct macro for the font change of a single argument or split the argument into two. 18:.BR "\-h\fP, \fB\-?\fP, \fB\-\-help" 28:.BR "\-c\fP, \fB\-\-copyright" 42:.BI "\-l\fP, \fB\-\-list" 51:.BI "\-w\fP, \fB\-\-writepkg" 56:.IR infilename 58:.BI "outfilename" 75:.BR "\-w\fP, \fB\-\-writepkg" 83:.BI "\-t\fP, \fB\-\-type" 90:.BI "\-t\fP, \fB\-w\fP, \fB\-s\fP" 92:.BI \-d 98:.BR "\-h\fP, \fB\-?\fP, \fB\-\-help" 161:.BI "\-l\fP, \fB\-\-list" -.-. 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. 80:from the input filename. If the input filename ends with an l, b, or e 87:former icuswap tool. For this mode, provide the infilename (and optional 124:to the package. The list can be a single filename with a 133:from the package. The list can be a single filename with a 142:from the package. The list can be a single filename with a 167:and are ignored. Empty lines are ignored. Lines where the first non-whitespace 173:wildcard character. The 175:matches zero or more characters. If 187:path will be prepended. The paths are only prepended to item 202:Copyright (C) 2006 IBM, Inc. and others. -.-. Output from "test-groff -mandoc -t -K utf8 -rF0 -rHY=0 -ww -b -z ": troff: backtrace: file '<stdin>':119 troff:<stdin>:119: warning: trailing space in the line troff: backtrace: file '<stdin>':171 troff:<stdin>:171: warning: trailing space in the line troff: backtrace: file '<stdin>':173 troff:<stdin>:173: warning: trailing space in the line
--- icupkg.8 2024-11-10 22:58:33.671545820 +0000 +++ icupkg.8.new 2024-11-10 23:36:27.683526603 +0000 @@ -15,17 +15,17 @@ archive .SH SYNOPSIS .B icupkg [ -.BR "\-h\fP, \fB\-?\fP, \fB\-\-help" +.B "\-h\fP, \fB\-?\fP, \fB\-\-help" ] [ -.BR "\-tl\fP, \fB\-\-type" " l" +.B "\-tl\fP, \fB\-\-type l" | -.BR "\-tb\fP, \fB\-\-type" " b" +.B "\-tb\fP, \fB\-\-type b" | -.BR "\-te\fP, \fB\-\-type" " e" +.B "\-te\fP, \fB\-\-type e" ] [ -.BR "\-c\fP, \fB\-\-copyright" +.B "\-c\fP, \fB\-\-copyright" | .BI "\-C\fP, \fB\-\-comment" " comment" ] @@ -39,7 +39,7 @@ archive .BI "\-x\fP, \fB\-\-extract" " list" ] [ -.BI "\-l\fP, \fB\-\-list" +.B "\-l\fP, \fB\-\-list" ] [ .BI "\-s\fP, \fB\-\-sourcedir" " source" @@ -48,14 +48,14 @@ archive .BI "\-d\fP, \fB\-\-destdir" " destination" ] [ -.BI "\-w\fP, \fB\-\-writepkg" +.B "\-w\fP, \fB\-\-writepkg" ] [ .BI "\-m\fP, \fB\-\-matchmode" " mode" ] -.IR infilename +.I infilename [ -.BI "outfilename" +.I outfilename ] .SH DESCRIPTION .B icupkg @@ -72,41 +72,45 @@ An ICU package is written if items are removed or added, or if the input and output filenames differ, or if the -.BR "\-w\fP, \fB\-\-writepkg" +.B "\-w\fP, \fB\-\-writepkg" option is set. .PP If the input filename is "new" then an empty package is created. If the output filename is missing, then it is automatically generated -from the input filename. If the input filename ends with an l, b, or e -matching its platform properties, then the output filename will -contain the letter from the -.BI "\-t\fP, \fB\-\-type" +from the input filename. +If the input filename ends with an l, b, or e matching its platform +properties, +then the output filename will contain the letter from the +.B "\-t\fP, \fB\-\-type" option. .PP -This tool can also be used to just swap a single ICU data file, replacing the -former icuswap tool. For this mode, provide the infilename (and optional -outfilename) for a non-package ICU data file. +This tool can also be used to just swap a single ICU data file, +replacing the former icuswap tool. +For this mode, +provide the infilename +(and optional outfilename) +for a non-package ICU data file. Allowed options include -.BI "\-t\fP, \fB\-w\fP, \fB\-s\fP" +.B "\-t\fP, \fB\-w\fP, \fB\-s\fP" and -.BI \-d +.B \-d . The filenames can be absolute, or relative to the source/dest dir paths. Other options are not allowed in this mode. .SH OPTIONS .TP -.BR "\-h\fP, \fB\-?\fP, \fB\-\-help" +.B "\-h\fP, \fB\-?\fP, \fB\-\-help" Print help about usage and exit. .TP -.BI "\-tl\fP, \fB\-\-type" " l" +.B "\-tl\fP, \fB\-\-type l" Output for little-endian/ASCII charset family. The output type defaults to the input type. .TP -.BI "\-tb\fP, \fB\-\-type" " b" +.B "\-tb\fP, \fB\-\-type b" Output for big-endian/ASCII charset family. The output type defaults to the input type. .TP -.BI "\-te\fP, \fB\-\-type" " e" +.B "\-te\fP, \fB\-\-type e" Output for big-endian/EBCDIC charset family. The output type defaults to the input type. .TP @@ -116,32 +120,38 @@ Include the ICU copyright notice in the .BI "\-C\fP, \fB\-\-comment" " comment" Include the specified .I comment -in the resulting data instead of the ICU copyright notice. +in the resulting data instead of the ICU copyright notice. .TP .BI "\-a\fP, \fB\-\-add" " list" Add items from the .I list -to the package. The list can be a single filename with a +to the package. +The list can be a single filename with a .B .txt -file extension containing a list of item filenames, or an ICU +file extension containing a list of item filenames, +or an ICU .B .dat package filename. .TP .BI "\-r\fP, \fB\-\-remove" " list" Remove items from the .I list -from the package. The list can be a single filename with a +from the package. +The list can be a single filename with a .B .txt -file extension containing a list of item filenames, or an ICU +file extension containing a list of item filenames, +or an ICU .B .dat package filename. .TP .BI "\-x\fP, \fB\-\-extract" " list" Extract items from the .I list -from the package. The list can be a single filename with a +from the package. +The list can be a single filename with a .B .txt -file extension containing a list of item filenames, or an ICU +file extension containing a list of item filenames, +or an ICU .B .dat package filename. .TP @@ -158,21 +168,24 @@ Set the destination directory to .IR destination . The default destination directory is the current directory. .TP -.BI "\-l\fP, \fB\-\-list" +.B "\-l\fP, \fB\-\-list" List the package items to stdout (after modifying the package). .SH LIST FILE SYNTAX Items are listed on one or more lines and separated by whitespace (space+tab). Comments begin with .B # -and are ignored. Empty lines are ignored. Lines where the first non-whitespace -character is one of "%&'()*+,-./:;<=>?_ are also ignored -to reserve for future syntax. +and are ignored. +Empty lines are ignored. +Lines where the first non-whitespace character is one of +"%&'()*+,-./:;<=>?_ are also ignored to reserve for future syntax. .PP -Items for removal or extraction may contain a single +Items for removal or extraction may contain a single .B * -wildcard character. The +wildcard character. +The .B * -matches zero or more characters. If +matches zero or more characters. +If .BI "\-m\fP, \fB\-\-matchmode" " noslash" is set, then the .B * @@ -184,9 +197,10 @@ Items must be listed relative to the pac .B "\fB\-\-sourcedir" or the .B "\fB\-\-destdir" -path will be prepended. The paths are only prepended to item -filenames while adding or extracting items, not to ICU .dat package or list -filenames. +path will be prepended. +The paths are only prepended to item filenames while +adding or extracting items, +not to ICU .dat package or list filenames. .PP Paths may contain .B / @@ -199,8 +213,8 @@ George Rhoten .SH VERSION 1.0 .SH COPYRIGHT -Copyright (C) 2006 IBM, Inc. and others. +Copyright (C) 2006 IBM, Inc.\& and others. .SH SEE ALSO -.BR pkgdata (1) +.BR pkgdata (1), .BR genrb (1)