Skip to content

Commit 2f26f10

Browse files
author
Peter Huene
committed
Fix missing package id error message for install tool command.
This commit fixes the error message that is displayed when the `install tool` command is not given a package id to install. Previously, only `packageId` was output, which was confusing. Fixes #8381.
1 parent 2c03ff9 commit 2f26f10

15 files changed

+69
-1
lines changed

src/dotnet/commands/dotnet-install/dotnet-install-tool/InstallToolCommandParser.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ public static Command InstallTool()
1212
{
1313
return Create.Command("tool",
1414
LocalizableStrings.CommandDescription,
15-
Accept.ExactlyOneArgument(o => "packageId")
15+
Accept.ExactlyOneArgument(errorMessage: o => LocalizableStrings.SpecifyExactlyOnePackageId)
1616
.With(name: LocalizableStrings.PackageIdArgumentName,
1717
description: LocalizableStrings.PackageIdArgumentDescription),
1818
Create.Option(

src/dotnet/commands/dotnet-install/dotnet-install-tool/LocalizableStrings.resx

+3
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,9 @@
123123
<data name="PackageIdArgumentDescription" xml:space="preserve">
124124
<value>NuGet Package Id of the tool to install.</value>
125125
</data>
126+
<data name="SpecifyExactlyOnePackageId" xml:space="preserve">
127+
<value>Please specify one tool Package Id to install.</value>
128+
</data>
126129
<data name="VersionOptionDescription" xml:space="preserve">
127130
<value>Version of the tool package in NuGet.</value>
128131
</data>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.cs.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.de.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.es.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.fr.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.it.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.ja.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.ko.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.pl.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.pt-BR.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.ru.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.tr.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.zh-Hans.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

src/dotnet/commands/dotnet-install/dotnet-install-tool/xlf/LocalizableStrings.zh-Hant.xlf

+5
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,11 @@ The error was:
9393
<target state="new">PACKAGE_ID</target>
9494
<note />
9595
</trans-unit>
96+
<trans-unit id="SpecifyExactlyOnePackageId">
97+
<source>Please specify one tool Package Id to install.</source>
98+
<target state="new">Please specify one tool Package Id to install.</target>
99+
<note />
100+
</trans-unit>
96101
</body>
97102
</file>
98103
</xliff>

0 commit comments

Comments
 (0)