Your message dated Wed, 3 Feb 2021 17:49:58 +0800
with message-id <[email protected]>
and subject line fortune-zh can display the foreground color of Chinese word 
correctly in terminal now
has caused the Debian Bug report #448059,
regarding Uses hard-coded ANSI color codes
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
448059: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=448059
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: fortune-zh
Version: 1.6
Severity: minor

These fortune files contain hard-coded ANSI escape codes to change the
foreground color of some lines.  This means that anything that does
not interpret ANSI escape codes will show garbage onscreen, for
example the less(1) command:

    fortune /usr/share/games/fortunes/tang300 | less
    ESC[32m《将赴吴兴登乐游原》ESC[m
    ESC[33m作者:杜牧ESC[m
    清时有味是无能,闲爱孤云静爱僧。
    欲把一麾江海去,乐游原上望昭陵。

The correct way to change foreground color in a shell script is to use
the tput(1) program, e.g.

    #!/bin/sh
    printf 'this is '
    tput setaf 4
    printf blue
    tput sgr0
    echo '!'

Since this cannot be done in a fortune file, I suggest the escape
codes simply be removed.

-- System Information:
Debian Release: lenny/sid
  APT prefers unstable
  APT policy: (990, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.22-2-amd64 (SMP w/1 CPU core)
Locale: LANG=en_AU.utf8, LC_CTYPE=en_AU.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages fortune-zh depends on:
ii  fortune-mod                   1:1.99.1-3 provides fortune cookies on demand
ii  zh-autoconvert                0.3.16-2   Chinese HZ/GB/BIG5/UNI/UTF7/UTF8 e

fortune-zh recommends no packages.

-- no debconf information



--- End Message ---
--- Begin Message ---
|Version: 2.96.1|

|
|

Hi,

    The way to use fortune-zh is run fortune-zh command in the terminal which support Chinese.

It's not use " fortune /usr/share/games/fortunes/tang300 | less".

The fortune command is belong to the package fortune-mod.

fortune-zh can display the foreground color of the Chinese word correctly in the terminal with "hard-coded ANSI color codes" now.

so, close this bug.


--
肖盛文 xiao sheng wen Faris Xiao
微信(wechat):atzlinux
《铜豌豆 Linux》https://www.atzlinux.com
基于 Debian 的 Linux 中文 桌面 操作系统
Debian QA page: https://qa.debian.org/developer.php?login=atzlinux%40sina.com
GnuPG Public Key: 0x00186602339240CB

Attachment: OpenPGP_0x00186602339240CB.asc
Description: application/pgp-keys

Attachment: OpenPGP_signature
Description: OpenPGP digital signature


--- End Message ---

Reply via email to