Sense *.ISO_8859-1 and *.KOI8-R locales from environment

PR: 4290
Submitted by: "Anatoly A. Orehovsky" <tolik@www.tomsk.su>
This commit is contained in:
Andrey A. Chernov 1997-09-15 02:03:13 +00:00
parent 40d7476321
commit dfb33229a0
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=29438
2 changed files with 32 additions and 2 deletions

View File

@ -2,4 +2,19 @@
# Provision of this shell script should not be taken to imply that use of
# GNU eqn with groff -Tascii|-Tlatin1 is supported.
exec @g@eqn -Tascii ${1+"$@"}
# Default device.
if test `expr "$LC_CTYPE" : ".*\.ISO_8859-1"` -gt 0 || \
test `expr "$LANG" : ".*\.ISO_8859-1"` -gt 0
then
T=-Tlatin1
else
if test `expr "$LC_CTYPE" : ".*\.KOI8-R"` -gt 0 || \
test `expr "$LANG" : ".*\.KOI8-R"` -gt 0
then
T=-Tkoi8-r
else
T=-Tascii
fi
fi
exec @g@eqn -T${T} ${1+"$@"}

View File

@ -2,4 +2,19 @@
# Provision of this shell script should not be taken to imply that use of
# GNU eqn with groff -Tascii|-Tlatin1 is supported.
exec @g@eqn -Tascii ${1+"$@"}
# Default device.
if test `expr "$LC_CTYPE" : ".*\.ISO_8859-1"` -gt 0 || \
test `expr "$LANG" : ".*\.ISO_8859-1"` -gt 0
then
T=-Tlatin1
else
if test `expr "$LC_CTYPE" : ".*\.KOI8-R"` -gt 0 || \
test `expr "$LANG" : ".*\.KOI8-R"` -gt 0
then
T=-Tkoi8-r
else
T=-Tascii
fi
fi
exec @g@eqn -T${T} ${1+"$@"}