uutils/coreutils

l10n: `LC_ALL` is ignored

开放

#8,922 创建于 2025年10月16日

 (1 条评论) (1 个反应) (0 位负责人)Rust (2,003 个派生)batch import
J - LocaleU - Allgood first issue

仓库指标

星标
 (23,984 个星标)
PR 合并指标
 (PR 指标待抓取)

描述

When setting the locale with LC_ALL, we ignore the specified locale and always use the English locale:

$ LC_ALL=fr_FR.UTF-8 cargo run -q sleep --help
Pause for NUMBER seconds.

Usage: sleep NUMBER[SUFFIX]...
       sleep OPTION
// snipped the rest of the output

It works fine with LANG:

$ LANG=fr_FR.UTF-8 cargo run -q sleep --help
Faire une pause de NOMBRE secondes.

Utilisation: sleep NOMBRE[SUFFIXE]...
       sleep OPTION
// snipped the rest of the output

GNU supports both environment variables:

$ LC_ALL=fr_FR.UTF-8 sleep --help
Utilisation : sleep NOMBRE[SUFFIXE]...
         ou : sleep OPTION
// snipped the rest of the output
$ LANG=fr_FR.UTF-8 sleep --help
Utilisation : sleep NOMBRE[SUFFIXE]...
         ou : sleep OPTION
// snipped the rest of the output

贡献者指南