diff --git a/localization/po/de.po b/localization/po/de.po index 67152a859..58b747b38 100644 --- a/localization/po/de.po +++ b/localization/po/de.po @@ -135,6 +135,10 @@ msgstr "%s (Zeile %u): " msgid "%s and %s are mutually exclusive" msgstr "" +#, c-format +msgid "%s command" +msgstr "" + #, c-format msgid "%s could not read response to Primary Device Attribute query after waiting for %d seconds. This is often due to a missing feature in your terminal. See 'help %s' or 'man fish-terminal-compatibility'. This %s process will no longer wait for outstanding queries, which disables some optional features." msgstr "" @@ -151,6 +155,10 @@ msgstr "" msgid "%s is a function" msgstr "%s ist eine Funktion" +#, c-format +msgid "%s variable" +msgstr "" + #, c-format msgid "%s, version %s" msgstr "" @@ -890,7 +898,7 @@ msgid "Abort (Alias for SIGABRT)" msgstr "" #, c-format -msgid "Active languages (%s):" +msgid "Active languages (source: %s):" msgstr "" msgid "Address boundary error" @@ -1821,17 +1829,10 @@ msgid "" "`help %s` will show an online version\n" msgstr "" -msgid "from command `status language set`" -msgstr "" - #, c-format msgid "from sourcing file %s\n" msgstr "aus der Quelldatei %s\n" -#, c-format -msgid "from variable %s" -msgstr "" - msgid "in command substitution\n" msgstr "in der Befehlsersetzung\n" diff --git a/localization/po/en.po b/localization/po/en.po index 10fc6f8b6..58136724e 100644 --- a/localization/po/en.po +++ b/localization/po/en.po @@ -133,6 +133,10 @@ msgstr "%s (line %u): " msgid "%s and %s are mutually exclusive" msgstr "" +#, c-format +msgid "%s command" +msgstr "" + #, c-format msgid "%s could not read response to Primary Device Attribute query after waiting for %d seconds. This is often due to a missing feature in your terminal. See 'help %s' or 'man fish-terminal-compatibility'. This %s process will no longer wait for outstanding queries, which disables some optional features." msgstr "" @@ -149,6 +153,10 @@ msgstr "" msgid "%s is a function" msgstr "" +#, c-format +msgid "%s variable" +msgstr "" + #, c-format msgid "%s, version %s" msgstr "" @@ -888,7 +896,7 @@ msgid "Abort (Alias for SIGABRT)" msgstr "Abort (Alias for SIGABRT)" #, c-format -msgid "Active languages (%s):" +msgid "Active languages (source: %s):" msgstr "" msgid "Address boundary error" @@ -1819,17 +1827,10 @@ msgid "" "`help %s` will show an online version\n" msgstr "" -msgid "from command `status language set`" -msgstr "" - #, c-format msgid "from sourcing file %s\n" msgstr "from sourcing file %s\n" -#, c-format -msgid "from variable %s" -msgstr "" - msgid "in command substitution\n" msgstr "in command substitution\n" diff --git a/localization/po/fr.po b/localization/po/fr.po index 48990b49c..a88e819d7 100644 --- a/localization/po/fr.po +++ b/localization/po/fr.po @@ -264,6 +264,10 @@ msgstr "%s (ligne %u) : " msgid "%s and %s are mutually exclusive" msgstr "" +#, c-format +msgid "%s command" +msgstr "" + #, c-format msgid "%s could not read response to Primary Device Attribute query after waiting for %d seconds. This is often due to a missing feature in your terminal. See 'help %s' or 'man fish-terminal-compatibility'. This %s process will no longer wait for outstanding queries, which disables some optional features." msgstr "%s n’a pas pu lire de réponse à une requête « Primary Device Attribute » après avoir attendu %d secondes. Ceci est souvent dû à une fonctionnalité manquante de votre terminal. Voir « help %s » ou « man fish-terminal-compatibility ». Le processus %s va désormais ignorer les requêtes en attente, ce qui désactive quelques fonctionnalités optionnelles." @@ -280,6 +284,10 @@ msgstr "%s est intégré\n" msgid "%s is a function" msgstr "%s est une fonction" +#, c-format +msgid "%s variable" +msgstr "" + #, c-format msgid "%s, version %s" msgstr "%s, version %s" @@ -1019,7 +1027,7 @@ msgid "Abort (Alias for SIGABRT)" msgstr "Abandon (Alias pour SIGABRT)" #, c-format -msgid "Active languages (%s):" +msgid "Active languages (source: %s):" msgstr "" msgid "Address boundary error" @@ -1950,17 +1958,10 @@ msgid "" "`help %s` will show an online version\n" msgstr "" -msgid "from command `status language set`" -msgstr "" - #, c-format msgid "from sourcing file %s\n" msgstr "du fichier source %s\n" -#, c-format -msgid "from variable %s" -msgstr "" - msgid "in command substitution\n" msgstr "dans la substitution de commande\n" diff --git a/localization/po/pl.po b/localization/po/pl.po index e0948e5b7..a8a2dd92d 100644 --- a/localization/po/pl.po +++ b/localization/po/pl.po @@ -129,6 +129,10 @@ msgstr "%s (linia %u): " msgid "%s and %s are mutually exclusive" msgstr "" +#, c-format +msgid "%s command" +msgstr "" + #, c-format msgid "%s could not read response to Primary Device Attribute query after waiting for %d seconds. This is often due to a missing feature in your terminal. See 'help %s' or 'man fish-terminal-compatibility'. This %s process will no longer wait for outstanding queries, which disables some optional features." msgstr "" @@ -145,6 +149,10 @@ msgstr "" msgid "%s is a function" msgstr "" +#, c-format +msgid "%s variable" +msgstr "" + #, c-format msgid "%s, version %s" msgstr "" @@ -884,7 +892,7 @@ msgid "Abort (Alias for SIGABRT)" msgstr "" #, c-format -msgid "Active languages (%s):" +msgid "Active languages (source: %s):" msgstr "" msgid "Address boundary error" @@ -1815,17 +1823,10 @@ msgid "" "`help %s` will show an online version\n" msgstr "" -msgid "from command `status language set`" -msgstr "" - #, c-format msgid "from sourcing file %s\n" msgstr "" -#, c-format -msgid "from variable %s" -msgstr "" - msgid "in command substitution\n" msgstr "w zastępstwie polecenia \n" diff --git a/localization/po/pt_BR.po b/localization/po/pt_BR.po index 6cbe61e60..ee1bb255f 100644 --- a/localization/po/pt_BR.po +++ b/localization/po/pt_BR.po @@ -134,6 +134,10 @@ msgstr "%s (linha %u): " msgid "%s and %s are mutually exclusive" msgstr "" +#, c-format +msgid "%s command" +msgstr "" + #, c-format msgid "%s could not read response to Primary Device Attribute query after waiting for %d seconds. This is often due to a missing feature in your terminal. See 'help %s' or 'man fish-terminal-compatibility'. This %s process will no longer wait for outstanding queries, which disables some optional features." msgstr "" @@ -150,6 +154,10 @@ msgstr "%s é um builtin\n" msgid "%s is a function" msgstr "%s é uma função" +#, c-format +msgid "%s variable" +msgstr "" + #, c-format msgid "%s, version %s" msgstr "" @@ -889,7 +897,7 @@ msgid "Abort (Alias for SIGABRT)" msgstr "Abortado (Outro nome para SIGABRT)" #, c-format -msgid "Active languages (%s):" +msgid "Active languages (source: %s):" msgstr "" msgid "Address boundary error" @@ -1820,17 +1828,10 @@ msgid "" "`help %s` will show an online version\n" msgstr "" -msgid "from command `status language set`" -msgstr "" - #, c-format msgid "from sourcing file %s\n" msgstr "do arquivo %s\n" -#, c-format -msgid "from variable %s" -msgstr "" - msgid "in command substitution\n" msgstr "na substituição de comando\n" diff --git a/localization/po/sv.po b/localization/po/sv.po index 3a9ca4dcb..748c3a49c 100644 --- a/localization/po/sv.po +++ b/localization/po/sv.po @@ -130,6 +130,10 @@ msgstr "" msgid "%s and %s are mutually exclusive" msgstr "" +#, c-format +msgid "%s command" +msgstr "" + #, c-format msgid "%s could not read response to Primary Device Attribute query after waiting for %d seconds. This is often due to a missing feature in your terminal. See 'help %s' or 'man fish-terminal-compatibility'. This %s process will no longer wait for outstanding queries, which disables some optional features." msgstr "" @@ -146,6 +150,10 @@ msgstr "" msgid "%s is a function" msgstr "" +#, c-format +msgid "%s variable" +msgstr "" + #, c-format msgid "%s, version %s" msgstr "" @@ -885,7 +893,7 @@ msgid "Abort (Alias for SIGABRT)" msgstr "Avbrott (Alias för SIGABRT)" #, c-format -msgid "Active languages (%s):" +msgid "Active languages (source: %s):" msgstr "" msgid "Address boundary error" @@ -1816,17 +1824,10 @@ msgid "" "`help %s` will show an online version\n" msgstr "" -msgid "from command `status language set`" -msgstr "" - #, c-format msgid "from sourcing file %s\n" msgstr "" -#, c-format -msgid "from variable %s" -msgstr "" - msgid "in command substitution\n" msgstr "i kommandosubstitution\n" diff --git a/localization/po/zh_CN.po b/localization/po/zh_CN.po index 07a087b40..4eadf70e2 100644 --- a/localization/po/zh_CN.po +++ b/localization/po/zh_CN.po @@ -156,6 +156,10 @@ msgstr "%s (行 %u): " msgid "%s and %s are mutually exclusive" msgstr "%s 与 %s 互斥" +#, c-format +msgid "%s command" +msgstr "" + #, c-format msgid "%s could not read response to Primary Device Attribute query after waiting for %d seconds. This is often due to a missing feature in your terminal. See 'help %s' or 'man fish-terminal-compatibility'. This %s process will no longer wait for outstanding queries, which disables some optional features." msgstr "%s 等待 %d 秒后仍无法读取 Primary Device Attribute 查询的响应。这通常是由于终端缺少相应功能所致。参见 'help %s' 或 'man fish-terminal-compatibility'。此 %s 进程将不再等待未处理的查询,这将禁用某些可选功能。" @@ -172,6 +176,10 @@ msgstr "%s 是一个内建命令\n" msgid "%s is a function" msgstr "%s 是一个函数" +#, c-format +msgid "%s variable" +msgstr "" + #, c-format msgid "%s, version %s" msgstr "%s,版本 %s" @@ -911,7 +919,7 @@ msgid "Abort (Alias for SIGABRT)" msgstr "中止 (SIGABRT 的别名)" #, c-format -msgid "Active languages (%s):" +msgid "Active languages (source: %s):" msgstr "" msgid "Address boundary error" @@ -1848,17 +1856,10 @@ msgstr "" "文档可能未安装。\n" "`help %s` 将显示在线版本\n" -msgid "from command `status language set`" -msgstr "" - #, c-format msgid "from sourcing file %s\n" msgstr "从源文件 %s\n" -#, c-format -msgid "from variable %s" -msgstr "" - msgid "in command substitution\n" msgstr "在命令替换中\n" diff --git a/localization/po/zh_TW.po b/localization/po/zh_TW.po index 3b2ac1172..7fa53841a 100644 --- a/localization/po/zh_TW.po +++ b/localization/po/zh_TW.po @@ -129,6 +129,10 @@ msgstr "%s(第 %u 行):" msgid "%s and %s are mutually exclusive" msgstr "%s 和 %s 不能同時使用" +#, c-format +msgid "%s command" +msgstr "" + #, c-format msgid "%s could not read response to Primary Device Attribute query after waiting for %d seconds. This is often due to a missing feature in your terminal. See 'help %s' or 'man fish-terminal-compatibility'. This %s process will no longer wait for outstanding queries, which disables some optional features." msgstr "%s 在過了 %d 秒後仍無法讀取到查詢主要裝置特性的回應。這通常是由於你的終端機缺少功能,參見「help %s」或「man fish-terminal-compatibility」。此 %s 行程不再會等待未決的查詢,一些非必要的功能將因此停用。" @@ -145,6 +149,10 @@ msgstr "%s 是內建命令\n" msgid "%s is a function" msgstr "%s 是函式" +#, c-format +msgid "%s variable" +msgstr "" + #, c-format msgid "%s, version %s" msgstr "%s,%s 版" @@ -885,7 +893,7 @@ msgid "Abort (Alias for SIGABRT)" msgstr "中止(SIGABRT 的別名)" #, c-format -msgid "Active languages (%s):" +msgid "Active languages (source: %s):" msgstr "" msgid "Address boundary error" @@ -1823,17 +1831,10 @@ msgstr "" "可能未安裝文件。\n" "「help %s」將顯示線上版本\n" -msgid "from command `status language set`" -msgstr "" - #, c-format msgid "from sourcing file %s\n" msgstr "在載入的檔案 %s\n" -#, c-format -msgid "from variable %s" -msgstr "" - msgid "in command substitution\n" msgstr "在命令替換\n" diff --git a/src/localization/mod.rs b/src/localization/mod.rs index 814f600e9..eac6ee206 100644 --- a/src/localization/mod.rs +++ b/src/localization/mod.rs @@ -142,7 +142,7 @@ pub fn status_language() -> WString { let localization_state = fish_gettext::status_language(); let mut result = WString::new(); localizable_consts!( - LANGUAGE_LIST_VARIABLE_ORIGIN "from variable %s" + LANGUAGE_LIST_VARIABLE_ORIGIN "%s variable" ); let origin_string = match localization_state.precedence_origin { LanguagePrecedenceOrigin::Default => wgettext!("default").to_owned(), @@ -153,10 +153,13 @@ pub fn status_language() -> WString { wgettext_fmt!(LANGUAGE_LIST_VARIABLE_ORIGIN, "LANGUAGE") } LanguagePrecedenceOrigin::StatusLanguage => { - wgettext!("from command `status language set`").to_owned() + wgettext_fmt!("%s command", "`status language set`") } }; - result.push_utfstr(&wgettext_fmt!("Active languages (%s):", origin_string)); + result.push_utfstr(&wgettext_fmt!( + "Active languages (source: %s):", + origin_string + )); append_space_separated_list(&mut result, &localization_state.language_precedence); result.push('\n'); diff --git a/tests/checks/message-localization.fish b/tests/checks/message-localization.fish index 1ecfb1403..04f524704 100644 --- a/tests/checks/message-localization.fish +++ b/tests/checks/message-localization.fish @@ -124,13 +124,13 @@ set --erase LC_MESSAGES set --erase LC_ALL set --erase LANGUAGE status language -# CHECK: Active languages (default): +# CHECK: Active languages (source: default): echo (_ file) # CHECK: file set -l LANGUAGE pt_BR de_DE status language -# CHECK: Active languages (from variable LANGUAGE): pt_BR de +# CHECK: Active languages (source: LANGUAGE variable): pt_BR de echo (_ file) # CHECK: arquivo @@ -138,37 +138,37 @@ echo (_ file) status language set fr_FR de pt_BR # CHECKERR: No catalogs available for language specifiers: fr_FR status language -# CHECK: Active languages (from command `status language set`): de pt_BR +# CHECK: Active languages (source: `status language set` command): de pt_BR echo (_ file) # CHECK: Datei set -l LANGUAGE zh_TW status language -# CHECK: Active languages (from command `status language set`): de pt_BR +# CHECK: Active languages (source: `status language set` command): de pt_BR echo (_ file) # CHECK: Datei set -l LC_MESSAGES C status language -# CHECK: Active languages (from command `status language set`): de pt_BR +# CHECK: Active languages (source: `status language set` command): de pt_BR echo (_ file) # CHECK: Datei status language unset status language -# CHECK: Active languages (from variable LC_MESSAGES): +# CHECK: Active languages (source: LC_MESSAGES variable): echo (_ file) # CHECK: file set --erase LC_MESSAGES status language -# CHECK: Active languages (from variable LANGUAGE): zh_TW +# CHECK: Active languages (source: LANGUAGE variable): zh_TW echo (_ file) # CHECK: 檔案 set --erase LANGUAGE status language -# CHECK: Active languages (default): +# CHECK: Active languages (source: default): echo (_ file) # CHECK: file