schwarze pushed a commit to branch master
in repository groff.

commit 33b5f7d7cccee9d38cc512e81f1e198ccdc8dfdf
Author: Ingo Schwarze <[email protected]>
Date:   Mon Dec 10 17:24:13 2018 +0100

    Further tweak shell script portability in the hdtbl fonts examples.
    
    As gbranden@ rightly observed, the number of characters in the
    character class :cntrl: is locale-dependent, POSIX says that the
    repeat count in the second argument to tr can be omitted, and the
    transliteration target will grow to fit the size of the source.
    This actually works on OpenBSD, Debian Jessie, Solaris 11, and
    Solaris 9, so it seems quite portable indeed.
    
    People keep discussing all kinds of fancy changes on the mailing
    list, but fail to address the question of which is the minimal
    change required to get portable behaviour during the last minute
    before release.  Thus, i'm just making a decision and using the
    minimal tweak suggested by gbranden@.
---
 contrib/hdtbl/examples/fonts_n.in | 2 +-
 contrib/hdtbl/examples/fonts_x.in | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/contrib/hdtbl/examples/fonts_n.in 
b/contrib/hdtbl/examples/fonts_n.in
index 72b5d2f..76d6661 100644
--- a/contrib/hdtbl/examples/fonts_n.in
+++ b/contrib/hdtbl/examples/fonts_n.in
@@ -54,7 +54,7 @@ along with this program.  If not, see 
<http://www.gnu.org/licenses/>.
 .  pso sh -c \
        "printf '%s' '.ds *f ' ; \
         ls \\*[fontpath]/dev\*[.T] \
-        | tr '[:cntrl:]' '[ *32]'"
+        | tr '[:cntrl:]' '[ *]'"
 .  \"  This dummy line is necessary; the preceding line eats it.
 .
 .  while !"\\*[*args]"" \{\
diff --git a/contrib/hdtbl/examples/fonts_x.in 
b/contrib/hdtbl/examples/fonts_x.in
index a4f2eab..081c8c7 100644
--- a/contrib/hdtbl/examples/fonts_x.in
+++ b/contrib/hdtbl/examples/fonts_x.in
@@ -54,7 +54,7 @@ along with this program.  If not, see 
<http://www.gnu.org/licenses/>.
 .  pso sh -c \
        "printf '%s' '.ds *f ' ; \
         ls \\*[fontpath]/dev\*[.T] \
-        | tr '[:cntrl:]' '[ *32]'"
+        | tr '[:cntrl:]' '[ *]'"
 .  \"  This dummy line is necessary; the preceding line eats it.
 .
 .  while !"\\*[*args]"" \{\

_______________________________________________
Groff-commit mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/groff-commit

Reply via email to