mirror of
https://github.com/nsnail/spectre.console.git
synced 2025-08-03 02:17:59 +08:00
Include resource files for additional cultures in HelpProvider. (#1717)
* Creation of Resource files for HelpProvider in the following cultures: it, ja, ko, pt, ru, and zh-Hans. * Add unit test files and update InlineData for new cultures. * Include --version option in CommandAppTests.Help.cs and update related output files
This commit is contained in:
@ -14,6 +14,7 @@ ARGUMENTE:
|
||||
OPTIONEN:
|
||||
STANDARDWERT
|
||||
-h, --help Zeigt Hilfe an
|
||||
-v, --version Zeigt Versionsinformationen an
|
||||
-a, --alive Indicates whether or not the animal is alive
|
||||
-n, --name <VALUE>
|
||||
--agility <VALUE> 10 The agility between 0 and 100
|
||||
|
@ -14,6 +14,7 @@ ARGUMENTS:
|
||||
OPTIONS:
|
||||
DEFAULT
|
||||
-h, --help Prints help information
|
||||
-v, --version Prints version information
|
||||
-a, --alive Indicates whether or not the animal is alive
|
||||
-n, --name <VALUE>
|
||||
--agility <VALUE> 10 The agility between 0 and 100
|
||||
|
@ -14,6 +14,7 @@ ARGUMENTS:
|
||||
OPTIONS:
|
||||
DÉFAUT
|
||||
-h, --help Affiche l'aide
|
||||
-v, --version Affiche la version
|
||||
-a, --alive Indicates whether or not the animal is alive
|
||||
-n, --name <VALUE>
|
||||
--agility <VALUE> 10 The agility between 0 and 100
|
||||
|
@ -0,0 +1,26 @@
|
||||
DESCRIZIONE:
|
||||
The lion command.
|
||||
|
||||
USO:
|
||||
myapp <TEETH> [LEGS] [OPZIONI] [COMANDO]
|
||||
|
||||
ESEMPI:
|
||||
myapp 20 --alive
|
||||
|
||||
ARGOMENTI:
|
||||
<TEETH> The number of teeth the lion has
|
||||
[LEGS] The number of legs
|
||||
|
||||
OPZIONI:
|
||||
PREDEFINITO
|
||||
-h, --help Visualizza le informazioni di aiuto
|
||||
-v, --version Visualizza le informazioni sulla versione
|
||||
-a, --alive Indicates whether or not the animal is alive
|
||||
-n, --name <VALUE>
|
||||
--agility <VALUE> 10 The agility between 0 and 100
|
||||
-c <CHILDREN> The number of children the lion has
|
||||
-d <DAY> Monday, Thursday The days the lion goes hunting
|
||||
-w, --weight [WEIGHT] The weight of the lion, in kgs
|
||||
|
||||
COMANDI:
|
||||
giraffe <LENGTH> The giraffe command
|
@ -0,0 +1,26 @@
|
||||
説明:
|
||||
The lion command.
|
||||
|
||||
使用法:
|
||||
myapp <TEETH> [LEGS] [オプション] [コマンド]
|
||||
|
||||
例:
|
||||
myapp 20 --alive
|
||||
|
||||
引数:
|
||||
<TEETH> The number of teeth the lion has
|
||||
[LEGS] The number of legs
|
||||
|
||||
オプション:
|
||||
デフォルト
|
||||
-h, --help ヘルプ情報を表示
|
||||
-v, --version バージョン情報を表示
|
||||
-a, --alive Indicates whether or not the animal is alive
|
||||
-n, --name <VALUE>
|
||||
--agility <VALUE> 10 The agility between 0 and 100
|
||||
-c <CHILDREN> The number of children the lion has
|
||||
-d <DAY> Monday, Thursday The days the lion goes hunting
|
||||
-w, --weight [WEIGHT] The weight of the lion, in kgs
|
||||
|
||||
コマンド群:
|
||||
giraffe <LENGTH> The giraffe command
|
@ -0,0 +1,26 @@
|
||||
설명:
|
||||
The lion command.
|
||||
|
||||
사용법:
|
||||
myapp <TEETH> [LEGS] [옵션] [명령]
|
||||
|
||||
예시:
|
||||
myapp 20 --alive
|
||||
|
||||
인수:
|
||||
<TEETH> The number of teeth the lion has
|
||||
[LEGS] The number of legs
|
||||
|
||||
옵션:
|
||||
기본값
|
||||
-h, --help 도움말 정보를 출력
|
||||
-v, --version 버전 정보를 출력
|
||||
-a, --alive Indicates whether or not the animal is alive
|
||||
-n, --name <VALUE>
|
||||
--agility <VALUE> 10 The agility between 0 and 100
|
||||
-c <CHILDREN> The number of children the lion has
|
||||
-d <DAY> Monday, Thursday The days the lion goes hunting
|
||||
-w, --weight [WEIGHT] The weight of the lion, in kgs
|
||||
|
||||
명령어:
|
||||
giraffe <LENGTH> The giraffe command
|
@ -0,0 +1,26 @@
|
||||
DESCRIÇÃO:
|
||||
The lion command.
|
||||
|
||||
USO:
|
||||
myapp <TEETH> [LEGS] [OPÇÕES] [COMANDO]
|
||||
|
||||
EXEMPLOS:
|
||||
myapp 20 --alive
|
||||
|
||||
ARGUMENTOS:
|
||||
<TEETH> The number of teeth the lion has
|
||||
[LEGS] The number of legs
|
||||
|
||||
OPÇÕES:
|
||||
PADRÃO
|
||||
-h, --help Exibe informações de ajuda
|
||||
-v, --version Exibe informações de versão
|
||||
-a, --alive Indicates whether or not the animal is alive
|
||||
-n, --name <VALUE>
|
||||
--agility <VALUE> 10 The agility between 0 and 100
|
||||
-c <CHILDREN> The number of children the lion has
|
||||
-d <DAY> Monday, Thursday The days the lion goes hunting
|
||||
-w, --weight [WEIGHT] The weight of the lion, in kgs
|
||||
|
||||
COMANDOS:
|
||||
giraffe <LENGTH> The giraffe command
|
@ -0,0 +1,26 @@
|
||||
ОПИСАНИЕ:
|
||||
The lion command.
|
||||
|
||||
ИСПОЛЬЗОВАНИЕ:
|
||||
myapp <TEETH> [LEGS] [ОПЦИИ] [КОМАНДА]
|
||||
|
||||
ПРИМЕРЫ:
|
||||
myapp 20 --alive
|
||||
|
||||
АРГУМЕНТЫ:
|
||||
<TEETH> The number of teeth the lion has
|
||||
[LEGS] The number of legs
|
||||
|
||||
ОПЦИИ:
|
||||
ПО УМОЛЧАНИЮ
|
||||
-h, --help Выводит информацию о помощи
|
||||
-v, --version Выводит информацию о версии
|
||||
-a, --alive Indicates whether or not the animal is alive
|
||||
-n, --name <VALUE>
|
||||
--agility <VALUE> 10 The agility between 0 and 100
|
||||
-c <CHILDREN> The number of children the lion has
|
||||
-d <DAY> Monday, Thursday The days the lion goes hunting
|
||||
-w, --weight [WEIGHT] The weight of the lion, in kgs
|
||||
|
||||
КОМАНДЫ:
|
||||
giraffe <LENGTH> The giraffe command
|
@ -14,6 +14,7 @@ ARGUMENT:
|
||||
VAL:
|
||||
STANDARD
|
||||
-h, --help Skriver ut hjälpinformation
|
||||
-v, --version Skriver ut versionsnummer
|
||||
-a, --alive Indicates whether or not the animal is alive
|
||||
-n, --name <VALUE>
|
||||
--agility <VALUE> 10 The agility between 0 and 100
|
||||
|
@ -0,0 +1,26 @@
|
||||
描述:
|
||||
The lion command.
|
||||
|
||||
用法:
|
||||
myapp <TEETH> [LEGS] [选项] [命令]
|
||||
|
||||
示例:
|
||||
myapp 20 --alive
|
||||
|
||||
参数:
|
||||
<TEETH> The number of teeth the lion has
|
||||
[LEGS] The number of legs
|
||||
|
||||
选项:
|
||||
默认
|
||||
-h, --help 显示帮助信息
|
||||
-v, --version 显示版本信息
|
||||
-a, --alive Indicates whether or not the animal is alive
|
||||
-n, --name <VALUE>
|
||||
--agility <VALUE> 10 The agility between 0 and 100
|
||||
-c <CHILDREN> The number of children the lion has
|
||||
-d <DAY> Monday, Thursday The days the lion goes hunting
|
||||
-w, --weight [WEIGHT] The weight of the lion, in kgs
|
||||
|
||||
命令列表:
|
||||
giraffe <LENGTH> The giraffe command
|
@ -303,6 +303,18 @@ public sealed partial class CommandAppTests
|
||||
[InlineData("sv-SE", "SV")]
|
||||
[InlineData("de", "DE")]
|
||||
[InlineData("de-DE", "DE")]
|
||||
[InlineData("it", "IT")]
|
||||
[InlineData("it-IT", "IT")]
|
||||
[InlineData("ja", "JA")]
|
||||
[InlineData("ja-JP", "JA")]
|
||||
[InlineData("ko", "KO")]
|
||||
[InlineData("ko-KR", "KO")]
|
||||
[InlineData("pt", "PT")]
|
||||
[InlineData("pt-BR", "PT")]
|
||||
[InlineData("ru", "RU")]
|
||||
[InlineData("ru-RU", "RU")]
|
||||
[InlineData("zh-Hans", "ZH-HANS")]
|
||||
[InlineData("zh-Hans-CN", "ZH-HANS")]
|
||||
[Expectation("Default_Without_Args_Additional")]
|
||||
public Task Should_Output_Default_Command_And_Additional_Commands_When_Default_Command_Has_Required_Parameters_And_Is_Called_Without_Args_Localised(string culture, string expectationPrefix)
|
||||
{
|
||||
@ -314,6 +326,7 @@ public sealed partial class CommandAppTests
|
||||
configurator.AddExample("20", "--alive");
|
||||
configurator.SetApplicationCulture(string.IsNullOrEmpty(culture) ? null : new CultureInfo(culture));
|
||||
configurator.SetApplicationName("myapp");
|
||||
configurator.SetApplicationVersion("1.0.0");
|
||||
configurator.AddCommand<GiraffeCommand>("giraffe");
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user