[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Unable to get GROFF_ENCODING to seep through to sourced subfiles
From: |
Bjarni Ingi Gislason |
Subject: |
Re: Unable to get GROFF_ENCODING to seep through to sourced subfiles |
Date: |
Tue, 10 Nov 2020 22:40:04 +0000 |
User-agent: |
Mutt/1.5.20 (2009-12-10) |
On Mon, Nov 09, 2020 at 03:58:38PM +0000, Dorai Sitaram via wrote:
> I have GROFF_ENCODING set to utf8, but this only works for the main file
> processed by groff, not to any subfiles that are sourced via .so .
> Giving the -s option to groff to force a soelim doesn't work either.
> Adding the -k option to force a preconv, whether before or after the -s
> option, doesn't work either. (I think regardless of the placement of -k and
> -s, -k happens before -s, hence the problem? Perhaps -k should be forced to
> happen last?)
> What does work is
> soelim mainDoc.ms | preconv | groff ...
> but it would be nice to avoid the pipelines with either options and/or
> environment variable.
> Thanks--d
By using the '-V' option one can see the pipeline,
that "groff" constructs, for example:
a) "groff -s -k -V file" shows:
preconv file | soelim | troff -Tps | grops
b) "GROFF_ENCODING=utf8 groff -s -V file" shows
preconv -eutf8 file | soelim | troff -Tps | grops
To get the right order, a patch must by applied,
for example, that in groff-bug #59442:
"groff -s -k -V file" shows then
soelim file | preconv | troff -Tps | grops
This does not work, as "preconv" needs an explicit encoding,
when it gets the data from the standard input.
"GROFF_ENCODING=utf8 groff -s -V file" shows then
soelim file | preconv -eutf8 | troff -Tps | grops
or the "-K" option for "groff" can be used instead of
"GROFF_ENCODING".
--
Bjarni I. Gislason