From 00f9c9f86f02b0d4d2faa831c06edab11a32221e Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 25 Sep 2025 14:11:09 +0000 Subject: [PATCH 1/6] Initial plan From bc5d218bc2e3569c69ee0e07d288999296d96462 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 25 Sep 2025 14:55:36 +0000 Subject: [PATCH 2/6] Add tool-specific package identity descriptions to replace generic examples Co-authored-by: baronfel <573979+baronfel@users.noreply.github.com> --- src/Cli/dotnet/CliStrings.resx | 3 +++ .../Commands/Tool/Install/ToolInstallCommandParser.cs | 2 +- src/Cli/dotnet/CommonArguments.cs | 8 ++++++++ src/Cli/dotnet/xlf/CliStrings.cs.xlf | 5 +++++ src/Cli/dotnet/xlf/CliStrings.de.xlf | 5 +++++ src/Cli/dotnet/xlf/CliStrings.es.xlf | 5 +++++ src/Cli/dotnet/xlf/CliStrings.fr.xlf | 5 +++++ src/Cli/dotnet/xlf/CliStrings.it.xlf | 5 +++++ src/Cli/dotnet/xlf/CliStrings.ja.xlf | 5 +++++ src/Cli/dotnet/xlf/CliStrings.ko.xlf | 5 +++++ src/Cli/dotnet/xlf/CliStrings.pl.xlf | 5 +++++ src/Cli/dotnet/xlf/CliStrings.pt-BR.xlf | 5 +++++ src/Cli/dotnet/xlf/CliStrings.ru.xlf | 5 +++++ src/Cli/dotnet/xlf/CliStrings.tr.xlf | 5 +++++ src/Cli/dotnet/xlf/CliStrings.zh-Hans.xlf | 5 +++++ src/Cli/dotnet/xlf/CliStrings.zh-Hant.xlf | 5 +++++ 16 files changed, 77 insertions(+), 1 deletion(-) diff --git a/src/Cli/dotnet/CliStrings.resx b/src/Cli/dotnet/CliStrings.resx index 211be41cbab6..f9682feec9c3 100644 --- a/src/Cli/dotnet/CliStrings.resx +++ b/src/Cli/dotnet/CliStrings.resx @@ -819,6 +819,9 @@ The default is 'false.' However, when targeting .NET 7 or lower, the default is Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference id and version must not be null. diff --git a/src/Cli/dotnet/Commands/Tool/Install/ToolInstallCommandParser.cs b/src/Cli/dotnet/Commands/Tool/Install/ToolInstallCommandParser.cs index f2c0109fe9fd..ee1802ec9946 100644 --- a/src/Cli/dotnet/Commands/Tool/Install/ToolInstallCommandParser.cs +++ b/src/Cli/dotnet/Commands/Tool/Install/ToolInstallCommandParser.cs @@ -10,7 +10,7 @@ namespace Microsoft.DotNet.Cli.Commands.Tool.Install; internal static class ToolInstallCommandParser { - public static readonly Argument PackageIdentityArgument = CommonArguments.RequiredPackageIdentityArgument(); + public static readonly Argument PackageIdentityArgument = CommonArguments.RequiredToolPackageIdentityArgument(); public static readonly Option VersionOption = new("--version") { diff --git a/src/Cli/dotnet/CommonArguments.cs b/src/Cli/dotnet/CommonArguments.cs index 994444113cbd..7dee359ef9ec 100644 --- a/src/Cli/dotnet/CommonArguments.cs +++ b/src/Cli/dotnet/CommonArguments.cs @@ -27,6 +27,14 @@ public static DynamicArgument RequiredPackageIdentityA Arity = ArgumentArity.ExactlyOne, }; + public static DynamicArgument RequiredToolPackageIdentityArgument() => + new("packageId") + { + Description = CliStrings.ToolPackageIdentityArgumentDescription, + CustomParser = (ArgumentResult argumentResult) => ParsePackageIdentityWithVersionSeparator(argumentResult.Tokens[0]?.Value)!.Value, + Arity = ArgumentArity.ExactlyOne, + }; + private static PackageIdentityWithRange? ParsePackageIdentityWithVersionSeparator(string? packageIdentity, char versionSeparator = '@') { if (string.IsNullOrEmpty(packageIdentity)) diff --git a/src/Cli/dotnet/xlf/CliStrings.cs.xlf b/src/Cli/dotnet/xlf/CliStrings.cs.xlf index 96994e69386c..9a7ea31f0918 100644 --- a/src/Cli/dotnet/xlf/CliStrings.cs.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.cs.xlf @@ -1088,6 +1088,11 @@ Výchozí hodnota je false. Pokud však cílíte na .NET 7 nebo nižší a je za Nástroj {0} (verze {1}) je už nainstalovaný. + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. Balíček {0} není nástroj .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.de.xlf b/src/Cli/dotnet/xlf/CliStrings.de.xlf index 7d82c933ec04..0ade9de07f1e 100644 --- a/src/Cli/dotnet/xlf/CliStrings.de.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.de.xlf @@ -1088,6 +1088,11 @@ Der Standardwert lautet FALSE. Wenn sie jedoch auf .NET 7 oder niedriger abziele Das Tool "{0}" (Version "{1}") ist bereits installiert. + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. Paket {0} ist kein .NET-Tool. diff --git a/src/Cli/dotnet/xlf/CliStrings.es.xlf b/src/Cli/dotnet/xlf/CliStrings.es.xlf index 41d4cb2d9cb5..489d490fb635 100644 --- a/src/Cli/dotnet/xlf/CliStrings.es.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.es.xlf @@ -1088,6 +1088,11 @@ El valor predeterminado es "false." Sin embargo, cuando el destino es .NET 7 o i La herramienta "{0}" (versión "{1}") ya está instalada. + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. El paquete {0} no es una herramienta de .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.fr.xlf b/src/Cli/dotnet/xlf/CliStrings.fr.xlf index b54e0e1895a9..b66889077db5 100644 --- a/src/Cli/dotnet/xlf/CliStrings.fr.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.fr.xlf @@ -1088,6 +1088,11 @@ La valeur par défaut est « false ». Toutefois, lorsque vous ciblez .NET 7 o L'outil '{0}' (version '{1}') est déjà installé. + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. Le package {0} n’est pas un outil .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.it.xlf b/src/Cli/dotnet/xlf/CliStrings.it.xlf index 48c5054887a0..4ffaf5398c50 100644 --- a/src/Cli/dotnet/xlf/CliStrings.it.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.it.xlf @@ -1088,6 +1088,11 @@ Il valore predefinito è 'false'. Tuttavia, quando la destinazione è .NET 7 o u Lo strumento '{0}' (versione '{1}') è già installato. + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. Il pacchetto {0} non è uno strumento .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.ja.xlf b/src/Cli/dotnet/xlf/CliStrings.ja.xlf index 8a30cdd0eb31..a0f74f8ab496 100644 --- a/src/Cli/dotnet/xlf/CliStrings.ja.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.ja.xlf @@ -1088,6 +1088,11 @@ The default is 'false.' However, when targeting .NET 7 or lower, the default is ツール '{0}' (バージョン '{1}') は既にインストールされています。 + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. パッケージ {0} は .NET ツールではありません。 diff --git a/src/Cli/dotnet/xlf/CliStrings.ko.xlf b/src/Cli/dotnet/xlf/CliStrings.ko.xlf index 1709a1c03189..43d15c632734 100644 --- a/src/Cli/dotnet/xlf/CliStrings.ko.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.ko.xlf @@ -1088,6 +1088,11 @@ The default is 'false.' However, when targeting .NET 7 or lower, the default is '{0}' 도구(버전 '{1}')가 이미 설치되어 있습니다. + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. {0} 패키지는 .NET 도구가 아닙니다. diff --git a/src/Cli/dotnet/xlf/CliStrings.pl.xlf b/src/Cli/dotnet/xlf/CliStrings.pl.xlf index 92db6aaf454a..6ff6269c3fab 100644 --- a/src/Cli/dotnet/xlf/CliStrings.pl.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.pl.xlf @@ -1088,6 +1088,11 @@ Wartość domyślna to „false”. Jednak w przypadku określania wartości doc Narzędzie „{0}” (wersja: „{1}”) jest już zainstalowane. + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. Pakiet {0} nie jest narzędziem platformy .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.pt-BR.xlf b/src/Cli/dotnet/xlf/CliStrings.pt-BR.xlf index 72421d704cb8..8954178defba 100644 --- a/src/Cli/dotnet/xlf/CliStrings.pt-BR.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.pt-BR.xlf @@ -1088,6 +1088,11 @@ O padrão é 'false.' No entanto, ao direcionar para .NET 7 ou inferior, o padr A ferramenta '{0}' (versão '{1}') já está instalada. + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. O pacote {0} não é uma ferramenta .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.ru.xlf b/src/Cli/dotnet/xlf/CliStrings.ru.xlf index b8d002306a5d..d708dbda69ab 100644 --- a/src/Cli/dotnet/xlf/CliStrings.ru.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.ru.xlf @@ -1088,6 +1088,11 @@ The default is 'false.' However, when targeting .NET 7 or lower, the default is Инструмент "{0}" (версия "{1}") уже установлен. + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. Пакет {0} не является средством .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.tr.xlf b/src/Cli/dotnet/xlf/CliStrings.tr.xlf index afea32011593..0c407796265b 100644 --- a/src/Cli/dotnet/xlf/CliStrings.tr.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.tr.xlf @@ -1088,6 +1088,11 @@ Varsayılan değer 'false.' Ancak çalışma zamanı tanımlayıcısı belirtild '{0}' aracı (sürüm '{1}') zaten yüklü. + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. {0} paketi bir .NET aracı değil. diff --git a/src/Cli/dotnet/xlf/CliStrings.zh-Hans.xlf b/src/Cli/dotnet/xlf/CliStrings.zh-Hans.xlf index e21979433126..e282bf165f03 100644 --- a/src/Cli/dotnet/xlf/CliStrings.zh-Hans.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.zh-Hans.xlf @@ -1088,6 +1088,11 @@ The default is 'false.' However, when targeting .NET 7 or lower, the default is 已安装工具“{0}”(版本“{1}”). + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. 包 {0} 不是 .NET 工具。 diff --git a/src/Cli/dotnet/xlf/CliStrings.zh-Hant.xlf b/src/Cli/dotnet/xlf/CliStrings.zh-Hant.xlf index 19454374cb33..a30e54101735 100644 --- a/src/Cli/dotnet/xlf/CliStrings.zh-Hant.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.zh-Hant.xlf @@ -1088,6 +1088,11 @@ The default is 'false.' However, when targeting .NET 7 or lower, the default is 工具 '{0}' ('{1}' 版) 已經安裝。 + + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + + Package {0} is not a .NET tool. 套件 {0} 不是 .NET 工具。 From d559dbf286bcde0ea1cc6926fcb3fa8363e9fc63 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 25 Sep 2025 14:56:36 +0000 Subject: [PATCH 3/6] Update copilot-instructions with dogfood testing approach for CLI changes Co-authored-by: baronfel <573979+baronfel@users.noreply.github.com> --- .github/copilot-instructions.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/copilot-instructions.md b/.github/copilot-instructions.md index 00e3e87beec2..c31c8405a9b1 100644 --- a/.github/copilot-instructions.md +++ b/.github/copilot-instructions.md @@ -16,6 +16,11 @@ Testing: - Examples: - `dotnet test test/dotnet.Tests/dotnet.Tests.csproj --filter "Name~ItShowsTheAppropriateMessageToTheUser"` - `dotnet exec artifacts/bin/redist/Debug/dotnet.Tests.dll -method "*ItShowsTheAppropriateMessageToTheUser*"` +- To test CLI command changes: + - Build the redist SDK: `./build.sh` from repo root + - Create a dogfood environment: `source eng/dogfood.sh` + - Test commands in the dogfood shell (e.g., `dnx --help`, `dotnet tool install --help`) + - The dogfood script sets up PATH and environment to use the newly built SDK Output Considerations: - When considering how output should look, solicit advice from baronfel. From e653e715c7bbe43b6b437d089241887a6a2d12db Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 25 Sep 2025 16:24:17 +0000 Subject: [PATCH 4/6] Refactor to use parameterized package identity argument methods per review feedback Co-authored-by: baronfel <573979+baronfel@users.noreply.github.com> --- .../Tool/Install/ToolInstallCommandParser.cs | 2 +- .../Tool/Update/ToolUpdateCommandParser.cs | 2 +- src/Cli/dotnet/CommonArguments.cs | 16 +++++++--------- 3 files changed, 9 insertions(+), 11 deletions(-) diff --git a/src/Cli/dotnet/Commands/Tool/Install/ToolInstallCommandParser.cs b/src/Cli/dotnet/Commands/Tool/Install/ToolInstallCommandParser.cs index ee1802ec9946..db33fa0b6bf7 100644 --- a/src/Cli/dotnet/Commands/Tool/Install/ToolInstallCommandParser.cs +++ b/src/Cli/dotnet/Commands/Tool/Install/ToolInstallCommandParser.cs @@ -10,7 +10,7 @@ namespace Microsoft.DotNet.Cli.Commands.Tool.Install; internal static class ToolInstallCommandParser { - public static readonly Argument PackageIdentityArgument = CommonArguments.RequiredToolPackageIdentityArgument(); + public static readonly Argument PackageIdentityArgument = CommonArguments.RequiredPackageIdentityArgument(CliStrings.ToolPackageIdentityArgumentDescription); public static readonly Option VersionOption = new("--version") { diff --git a/src/Cli/dotnet/Commands/Tool/Update/ToolUpdateCommandParser.cs b/src/Cli/dotnet/Commands/Tool/Update/ToolUpdateCommandParser.cs index 1bbb466a6af9..5940fbd37174 100644 --- a/src/Cli/dotnet/Commands/Tool/Update/ToolUpdateCommandParser.cs +++ b/src/Cli/dotnet/Commands/Tool/Update/ToolUpdateCommandParser.cs @@ -9,7 +9,7 @@ namespace Microsoft.DotNet.Cli.Commands.Tool.Update; internal static class ToolUpdateCommandParser { - public static readonly Argument PackageIdentityArgument = CommonArguments.OptionalPackageIdentityArgument(); + public static readonly Argument PackageIdentityArgument = CommonArguments.OptionalPackageIdentityArgument(CliStrings.ToolPackageIdentityArgumentDescription); public static readonly Option UpdateAllOption = ToolAppliedOption.UpdateAllOption; diff --git a/src/Cli/dotnet/CommonArguments.cs b/src/Cli/dotnet/CommonArguments.cs index 7dee359ef9ec..5e1d9984bec6 100644 --- a/src/Cli/dotnet/CommonArguments.cs +++ b/src/Cli/dotnet/CommonArguments.cs @@ -12,25 +12,23 @@ namespace Microsoft.DotNet.Cli internal class CommonArguments { public static DynamicArgument OptionalPackageIdentityArgument() => + OptionalPackageIdentityArgument(CliStrings.PackageIdentityArgumentDescription); + + public static DynamicArgument OptionalPackageIdentityArgument(string description) => new("packageId") { - Description = CliStrings.PackageIdentityArgumentDescription, + Description = description, CustomParser = (ArgumentResult argumentResult) => ParsePackageIdentityWithVersionSeparator(argumentResult.Tokens[0]?.Value), Arity = ArgumentArity.ZeroOrOne, }; public static DynamicArgument RequiredPackageIdentityArgument() => - new("packageId") - { - Description = CliStrings.PackageIdentityArgumentDescription, - CustomParser = (ArgumentResult argumentResult) => ParsePackageIdentityWithVersionSeparator(argumentResult.Tokens[0]?.Value)!.Value, - Arity = ArgumentArity.ExactlyOne, - }; + RequiredPackageIdentityArgument(CliStrings.PackageIdentityArgumentDescription); - public static DynamicArgument RequiredToolPackageIdentityArgument() => + public static DynamicArgument RequiredPackageIdentityArgument(string description) => new("packageId") { - Description = CliStrings.ToolPackageIdentityArgumentDescription, + Description = description, CustomParser = (ArgumentResult argumentResult) => ParsePackageIdentityWithVersionSeparator(argumentResult.Tokens[0]?.Value)!.Value, Arity = ArgumentArity.ExactlyOne, }; From fea93b8a33112ac10e3b797d50b68a5ac17c0d12 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 25 Sep 2025 16:26:53 +0000 Subject: [PATCH 5/6] Update CLI snapshot test baselines for tool-specific package examples Co-authored-by: baronfel <573979+baronfel@users.noreply.github.com> --- .../DotnetCliSnapshotTests.VerifyCompletions.verified.zsh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/dotnet.Tests/CompletionTests/snapshots/zsh/DotnetCliSnapshotTests.VerifyCompletions.verified.zsh b/test/dotnet.Tests/CompletionTests/snapshots/zsh/DotnetCliSnapshotTests.VerifyCompletions.verified.zsh index f574e688099f..0718ee370c8f 100644 --- a/test/dotnet.Tests/CompletionTests/snapshots/zsh/DotnetCliSnapshotTests.VerifyCompletions.verified.zsh +++ b/test/dotnet.Tests/CompletionTests/snapshots/zsh/DotnetCliSnapshotTests.VerifyCompletions.verified.zsh @@ -1103,7 +1103,7 @@ _testhost() { '--allow-roll-forward[Allow a .NET tool to roll forward to newer versions of the .NET runtime if the runtime it targets isn'\''t installed.]' \ '--help[Show command line help.]' \ '-h[Show command line help.]' \ - ':packageId -- Package reference in the form of a package identifier like '\''Newtonsoft.Json'\'' or package identifier and version separated by '\''@'\'' like '\''Newtonsoft.Json@13.0.3'\''.:->dotnet_dynamic_complete' \ + ':packageId -- Package reference in the form of a package identifier like '\''dotnetsay'\'' or package identifier and version separated by '\''@'\'' like '\''dotnetsay@2.1.7'\''.:->dotnet_dynamic_complete' \ && ret=0 case $state in (dotnet_dynamic_complete) @@ -1151,7 +1151,7 @@ _testhost() { '--all[Update all tools.]' \ '--help[Show command line help.]' \ '-h[Show command line help.]' \ - '::packageId -- Package reference in the form of a package identifier like '\''Newtonsoft.Json'\'' or package identifier and version separated by '\''@'\'' like '\''Newtonsoft.Json@13.0.3'\''.:->dotnet_dynamic_complete' \ + '::packageId -- Package reference in the form of a package identifier like '\''dotnetsay'\'' or package identifier and version separated by '\''@'\'' like '\''dotnetsay@2.1.7'\''.:->dotnet_dynamic_complete' \ && ret=0 case $state in (dotnet_dynamic_complete) @@ -1229,7 +1229,7 @@ _testhost() { '-v=[Set the MSBuild verbosity level. Allowed values are q\[uiet\], m\[inimal\], n\[ormal\], d\[etailed\], and diag\[nostic\].]:LEVEL:((d\:"d" detailed\:"detailed" diag\:"diag" diagnostic\:"diagnostic" m\:"m" minimal\:"minimal" n\:"n" normal\:"normal" q\:"q" quiet\:"quiet" ))' \ '--help[Show command line help.]' \ '-h[Show command line help.]' \ - ':packageId -- Package reference in the form of a package identifier like '\''Newtonsoft.Json'\'' or package identifier and version separated by '\''@'\'' like '\''Newtonsoft.Json@13.0.3'\''.:->dotnet_dynamic_complete' \ + ':packageId -- Package reference in the form of a package identifier like '\''dotnetsay'\'' or package identifier and version separated by '\''@'\'' like '\''dotnetsay@2.1.7'\''.:->dotnet_dynamic_complete' \ '*::commandArguments -- Arguments forwarded to the tool: ' \ && ret=0 case $state in From 3b917c6899f0be533d1cc8c452c24e8d5ca1b7c5 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 25 Sep 2025 17:32:52 +0000 Subject: [PATCH 6/6] Use single format string with placeholders instead of separate resource strings Co-authored-by: baronfel <573979+baronfel@users.noreply.github.com> --- src/Cli/dotnet/CliStrings.resx | 5 +---- .../Tool/Install/ToolInstallCommandParser.cs | 2 +- .../Commands/Tool/Update/ToolUpdateCommandParser.cs | 2 +- src/Cli/dotnet/CommonArguments.cs | 12 ++++++------ src/Cli/dotnet/xlf/CliStrings.cs.xlf | 9 ++------- src/Cli/dotnet/xlf/CliStrings.de.xlf | 9 ++------- src/Cli/dotnet/xlf/CliStrings.es.xlf | 9 ++------- src/Cli/dotnet/xlf/CliStrings.fr.xlf | 9 ++------- src/Cli/dotnet/xlf/CliStrings.it.xlf | 9 ++------- src/Cli/dotnet/xlf/CliStrings.ja.xlf | 9 ++------- src/Cli/dotnet/xlf/CliStrings.ko.xlf | 9 ++------- src/Cli/dotnet/xlf/CliStrings.pl.xlf | 9 ++------- src/Cli/dotnet/xlf/CliStrings.pt-BR.xlf | 9 ++------- src/Cli/dotnet/xlf/CliStrings.ru.xlf | 9 ++------- src/Cli/dotnet/xlf/CliStrings.tr.xlf | 9 ++------- src/Cli/dotnet/xlf/CliStrings.zh-Hans.xlf | 9 ++------- src/Cli/dotnet/xlf/CliStrings.zh-Hant.xlf | 9 ++------- 17 files changed, 35 insertions(+), 103 deletions(-) diff --git a/src/Cli/dotnet/CliStrings.resx b/src/Cli/dotnet/CliStrings.resx index f9682feec9c3..bd4864527b9c 100644 --- a/src/Cli/dotnet/CliStrings.resx +++ b/src/Cli/dotnet/CliStrings.resx @@ -817,10 +817,7 @@ The default is 'false.' However, when targeting .NET 7 or lower, the default is {Locked="dotnet workload update"} - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. Package reference id and version must not be null. diff --git a/src/Cli/dotnet/Commands/Tool/Install/ToolInstallCommandParser.cs b/src/Cli/dotnet/Commands/Tool/Install/ToolInstallCommandParser.cs index db33fa0b6bf7..009b270947a3 100644 --- a/src/Cli/dotnet/Commands/Tool/Install/ToolInstallCommandParser.cs +++ b/src/Cli/dotnet/Commands/Tool/Install/ToolInstallCommandParser.cs @@ -10,7 +10,7 @@ namespace Microsoft.DotNet.Cli.Commands.Tool.Install; internal static class ToolInstallCommandParser { - public static readonly Argument PackageIdentityArgument = CommonArguments.RequiredPackageIdentityArgument(CliStrings.ToolPackageIdentityArgumentDescription); + public static readonly Argument PackageIdentityArgument = CommonArguments.RequiredPackageIdentityArgument("dotnetsay", "2.1.7"); public static readonly Option VersionOption = new("--version") { diff --git a/src/Cli/dotnet/Commands/Tool/Update/ToolUpdateCommandParser.cs b/src/Cli/dotnet/Commands/Tool/Update/ToolUpdateCommandParser.cs index 5940fbd37174..f29fce2f7086 100644 --- a/src/Cli/dotnet/Commands/Tool/Update/ToolUpdateCommandParser.cs +++ b/src/Cli/dotnet/Commands/Tool/Update/ToolUpdateCommandParser.cs @@ -9,7 +9,7 @@ namespace Microsoft.DotNet.Cli.Commands.Tool.Update; internal static class ToolUpdateCommandParser { - public static readonly Argument PackageIdentityArgument = CommonArguments.OptionalPackageIdentityArgument(CliStrings.ToolPackageIdentityArgumentDescription); + public static readonly Argument PackageIdentityArgument = CommonArguments.OptionalPackageIdentityArgument("dotnetsay", "2.1.7"); public static readonly Option UpdateAllOption = ToolAppliedOption.UpdateAllOption; diff --git a/src/Cli/dotnet/CommonArguments.cs b/src/Cli/dotnet/CommonArguments.cs index 5e1d9984bec6..bef42994416f 100644 --- a/src/Cli/dotnet/CommonArguments.cs +++ b/src/Cli/dotnet/CommonArguments.cs @@ -12,23 +12,23 @@ namespace Microsoft.DotNet.Cli internal class CommonArguments { public static DynamicArgument OptionalPackageIdentityArgument() => - OptionalPackageIdentityArgument(CliStrings.PackageIdentityArgumentDescription); + OptionalPackageIdentityArgument("Newtonsoft.Json", "13.0.3"); - public static DynamicArgument OptionalPackageIdentityArgument(string description) => + public static DynamicArgument OptionalPackageIdentityArgument(string examplePackage, string exampleVersion) => new("packageId") { - Description = description, + Description = string.Format(CliStrings.PackageIdentityArgumentDescription, examplePackage, exampleVersion), CustomParser = (ArgumentResult argumentResult) => ParsePackageIdentityWithVersionSeparator(argumentResult.Tokens[0]?.Value), Arity = ArgumentArity.ZeroOrOne, }; public static DynamicArgument RequiredPackageIdentityArgument() => - RequiredPackageIdentityArgument(CliStrings.PackageIdentityArgumentDescription); + RequiredPackageIdentityArgument("Newtonsoft.Json", "13.0.3"); - public static DynamicArgument RequiredPackageIdentityArgument(string description) => + public static DynamicArgument RequiredPackageIdentityArgument(string examplePackage, string exampleVersion) => new("packageId") { - Description = description, + Description = string.Format(CliStrings.PackageIdentityArgumentDescription, examplePackage, exampleVersion), CustomParser = (ArgumentResult argumentResult) => ParsePackageIdentityWithVersionSeparator(argumentResult.Tokens[0]?.Value)!.Value, Arity = ArgumentArity.ExactlyOne, }; diff --git a/src/Cli/dotnet/xlf/CliStrings.cs.xlf b/src/Cli/dotnet/xlf/CliStrings.cs.xlf index 9a7ea31f0918..793563fbddd5 100644 --- a/src/Cli/dotnet/xlf/CliStrings.cs.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.cs.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - Odkaz na balíček ve formě identifikátoru balíčku, jako je Newtonsoft.Json, nebo identifikátor balíčku a verze oddělené znakem @, například Newtonsoft.Json@13.0.3. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ Výchozí hodnota je false. Pokud však cílíte na .NET 7 nebo nižší a je za Nástroj {0} (verze {1}) je už nainstalovaný. - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. Balíček {0} není nástroj .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.de.xlf b/src/Cli/dotnet/xlf/CliStrings.de.xlf index 0ade9de07f1e..75a8ea0992ba 100644 --- a/src/Cli/dotnet/xlf/CliStrings.de.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.de.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - Paketverweis in Form eines Paketbezeichners wie "Newtonsoft.Json" oder Paketbezeichner und -version getrennt durch "@" wie "Newtonsoft.Json@13.0.3". + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ Der Standardwert lautet FALSE. Wenn sie jedoch auf .NET 7 oder niedriger abziele Das Tool "{0}" (Version "{1}") ist bereits installiert. - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. Paket {0} ist kein .NET-Tool. diff --git a/src/Cli/dotnet/xlf/CliStrings.es.xlf b/src/Cli/dotnet/xlf/CliStrings.es.xlf index 489d490fb635..e15989731524 100644 --- a/src/Cli/dotnet/xlf/CliStrings.es.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.es.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - Referencia de paquete en forma de identificador de paquete como "Newtonsoft.Json" o identificador de paquete y versión separados por "@", como "Newtonsoft.Json@13.0.3". + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ El valor predeterminado es "false." Sin embargo, cuando el destino es .NET 7 o i La herramienta "{0}" (versión "{1}") ya está instalada. - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. El paquete {0} no es una herramienta de .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.fr.xlf b/src/Cli/dotnet/xlf/CliStrings.fr.xlf index b66889077db5..c559d991fdb8 100644 --- a/src/Cli/dotnet/xlf/CliStrings.fr.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.fr.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - Référence de package sous la forme d’un identificateur de package tel que « Newtonsoft.Json » ou d’un identificateur de package et d’une version séparés par « @ », comme « Newtonsoft.Json@13.0.3 ». + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ La valeur par défaut est « false ». Toutefois, lorsque vous ciblez .NET 7 o L'outil '{0}' (version '{1}') est déjà installé. - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. Le package {0} n’est pas un outil .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.it.xlf b/src/Cli/dotnet/xlf/CliStrings.it.xlf index 4ffaf5398c50..632432b2b28e 100644 --- a/src/Cli/dotnet/xlf/CliStrings.it.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.it.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - Riferimento al pacchetto sotto forma di identificatore di pacchetto, ad esempio 'Newtonsoft.Json', oppure identificatore e versione di pacchetto separati da '@', ad esempio 'Newtonsoft.Json@13.0.3'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ Il valore predefinito è 'false'. Tuttavia, quando la destinazione è .NET 7 o u Lo strumento '{0}' (versione '{1}') è già installato. - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. Il pacchetto {0} non è uno strumento .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.ja.xlf b/src/Cli/dotnet/xlf/CliStrings.ja.xlf index a0f74f8ab496..4ec60d0c7eee 100644 --- a/src/Cli/dotnet/xlf/CliStrings.ja.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.ja.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - 'Newtonsoft.Json' のようなパッケージ識別子の形式のパッケージ参照、または 'Newtonsoft.Json@13.0.3' のような '@' で区切られたパッケージ識別子とバージョンです。 + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ The default is 'false.' However, when targeting .NET 7 or lower, the default is ツール '{0}' (バージョン '{1}') は既にインストールされています。 - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. パッケージ {0} は .NET ツールではありません。 diff --git a/src/Cli/dotnet/xlf/CliStrings.ko.xlf b/src/Cli/dotnet/xlf/CliStrings.ko.xlf index 43d15c632734..c65066c2341e 100644 --- a/src/Cli/dotnet/xlf/CliStrings.ko.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.ko.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - 'Newtonsoft.Json'과 같은 패키지 식별자 또는 'Newtonsoft.Json@13.0.3'과 같이 '@'로 구분된 패키지 식별자 및 버전 형식의 패키지 참조입니다. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ The default is 'false.' However, when targeting .NET 7 or lower, the default is '{0}' 도구(버전 '{1}')가 이미 설치되어 있습니다. - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. {0} 패키지는 .NET 도구가 아닙니다. diff --git a/src/Cli/dotnet/xlf/CliStrings.pl.xlf b/src/Cli/dotnet/xlf/CliStrings.pl.xlf index 6ff6269c3fab..47183ec7a676 100644 --- a/src/Cli/dotnet/xlf/CliStrings.pl.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.pl.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - Odwołanie do pakietu w postaci identyfikatora pakietu, takiego jak „Newtonsoft.Json” lub identyfikator pakietu i wersja rozdzielone znakiem „@”, na przykład „Newtonsoft.Json@13.0.3”. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ Wartość domyślna to „false”. Jednak w przypadku określania wartości doc Narzędzie „{0}” (wersja: „{1}”) jest już zainstalowane. - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. Pakiet {0} nie jest narzędziem platformy .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.pt-BR.xlf b/src/Cli/dotnet/xlf/CliStrings.pt-BR.xlf index 8954178defba..fccf80013c69 100644 --- a/src/Cli/dotnet/xlf/CliStrings.pt-BR.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.pt-BR.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - Referência do pacote na forma de um identificador de pacote como 'Newtonsoft.Json' ou identificador e versão do pacote separados por '@', como 'Newtonsoft.Json\@13.0.3'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ O padrão é 'false.' No entanto, ao direcionar para .NET 7 ou inferior, o padr A ferramenta '{0}' (versão '{1}') já está instalada. - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. O pacote {0} não é uma ferramenta .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.ru.xlf b/src/Cli/dotnet/xlf/CliStrings.ru.xlf index d708dbda69ab..3814f20f1ca5 100644 --- a/src/Cli/dotnet/xlf/CliStrings.ru.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.ru.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - Ссылка на пакет в виде идентификатора пакета, например "Newtonsoft.Json", или идентификатора пакета и версии, разделенных "@", например "Newtonsoft.Json@13.0.3". + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ The default is 'false.' However, when targeting .NET 7 or lower, the default is Инструмент "{0}" (версия "{1}") уже установлен. - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. Пакет {0} не является средством .NET. diff --git a/src/Cli/dotnet/xlf/CliStrings.tr.xlf b/src/Cli/dotnet/xlf/CliStrings.tr.xlf index 0c407796265b..e6dc0a5df795 100644 --- a/src/Cli/dotnet/xlf/CliStrings.tr.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.tr.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - 'Newtonsoft.Json' gibi bir paket tanımlayıcısı veya 'Newtonsoft.Json@13.0.3' gibi '@' ile ayrılmış paket tanımlayıcısı ve sürümü şeklinde paket referansı. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ Varsayılan değer 'false.' Ancak çalışma zamanı tanımlayıcısı belirtild '{0}' aracı (sürüm '{1}') zaten yüklü. - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. {0} paketi bir .NET aracı değil. diff --git a/src/Cli/dotnet/xlf/CliStrings.zh-Hans.xlf b/src/Cli/dotnet/xlf/CliStrings.zh-Hans.xlf index e282bf165f03..7dc1e93e52e6 100644 --- a/src/Cli/dotnet/xlf/CliStrings.zh-Hans.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.zh-Hans.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - 包引用采用包标识符形式,如 'Newtonsoft.Json',或采用以 ‘@’ 分隔包标识符和版本的形式,如 ‘Newtonsoft.Json@13.0.3’。 + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ The default is 'false.' However, when targeting .NET 7 or lower, the default is 已安装工具“{0}”(版本“{1}”). - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. 包 {0} 不是 .NET 工具。 diff --git a/src/Cli/dotnet/xlf/CliStrings.zh-Hant.xlf b/src/Cli/dotnet/xlf/CliStrings.zh-Hant.xlf index a30e54101735..bd3384fb8061 100644 --- a/src/Cli/dotnet/xlf/CliStrings.zh-Hant.xlf +++ b/src/Cli/dotnet/xlf/CliStrings.zh-Hant.xlf @@ -783,8 +783,8 @@ setx PATH "%PATH%;{0}" - Package reference in the form of a package identifier like 'Newtonsoft.Json' or package identifier and version separated by '@' like 'Newtonsoft.Json@13.0.3'. - 套件參考的格式為套件識別碼,例如 'Newtonsoft.Json',或是以 '@' 分隔的套件識別碼和版本,例如 'Newtonsoft.Json@13.0.3'。 + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. + Package reference in the form of a package identifier like '{0}' or package identifier and version separated by '@' like '{0}@{1}'. @@ -1088,11 +1088,6 @@ The default is 'false.' However, when targeting .NET 7 or lower, the default is 工具 '{0}' ('{1}' 版) 已經安裝。 - - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - Package reference in the form of a package identifier like 'dotnetsay' or package identifier and version separated by '@' like 'dotnetsay@2.1.7'. - - Package {0} is not a .NET tool. 套件 {0} 不是 .NET 工具。