Skip to content

Commit 83609ce

Browse files
authored
Merge pull request dotnet#8408 from peterhuene/install-tool-strings
Fix missing package id error message for install tool command.
2 parents edc6697 + 5b696e4 commit 83609ce

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+1622
-1275
lines changed

scripts/cli-build-env.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ done
1313

1414
REPO_ROOT="$( cd -P "$( dirname "$SOURCE" )/../" && pwd )"
1515

16-
STAGE0_DIR=$REPO_ROOT.dotnet_stage0/x64
16+
STAGE0_DIR=$REPO_ROOT/.dotnet_stage0/x64
1717
export PATH=$STAGE0_DIR:$PATH
1818

1919

src/dotnet/commands/dotnet-help/LocalizableStrings.resx

+1-1
Original file line numberDiff line numberDiff line change
@@ -268,6 +268,6 @@
268268
<value>Path to additional deps.json file.</value>
269269
</data>
270270
<data name="InstallDefinition" xml:space="preserve">
271-
<value>Add item to development environment.</value>
271+
<value>Installs an item into the development environment.</value>
272272
</data>
273273
</root>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.cs.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.de.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.es.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.fr.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.it.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.ja.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.ko.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.pl.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.pt-BR.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.ru.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.tr.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.zh-Hans.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-help/xlf/LocalizableStrings.zh-Hant.xlf

+2-2
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,8 @@
253253
<note />
254254
</trans-unit>
255255
<trans-unit id="InstallDefinition">
256-
<source>Add item to development environment.</source>
257-
<target state="new">Add item to development environment.</target>
256+
<source>Installs an item into the development environment.</source>
257+
<target state="new">Installs an item into the development environment.</target>
258258
<note />
259259
</trans-unit>
260260
</body>

src/dotnet/commands/dotnet-install/InstallCommandParser.cs

+2-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ internal static class InstallCommandParser
1111
public static Command Install()
1212
{
1313
return Create.Command(
14-
"install", LocalizableStrings.InstallCommandDefinition,
14+
"install",
15+
LocalizableStrings.CommandDescription,
1516
Accept.NoArguments(),
1617
CommonOptions.HelpOption(),
1718
InstallToolCommandParser.InstallTool());

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

+3-52
Original file line numberDiff line numberDiff line change
@@ -117,59 +117,10 @@
117117
<resheader name="writer">
118118
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
119119
</resheader>
120-
<data name="SourceOptionDescription" xml:space="preserve">
121-
<value>Specifies a NuGet package source to use during installation.</value>
122-
</data>
123-
<data name="SourceOptionName" xml:space="preserve">
124-
<value>SOURCE</value>
125-
</data>
126-
<data name="FailedToAddPackage" xml:space="preserve">
127-
<value>Failed to add package.
128-
WorkingDirectory: {0}
129-
Arguments: {1}
130-
Output: {2}{3}</value>
131-
</data>
132-
<data name="FailedToRestorePackage" xml:space="preserve">
133-
<value>Failed to restore package.
134-
WorkingDirectory: {0}
135-
Arguments: {1}
136-
Output: {2}{3}</value>
137-
</data>
138-
<data name="InstallationSucceeded" xml:space="preserve">
139-
<value>
140-
The installation succeeded. If there is no other instruction. You can type the following command in shell directly to invoke: {0}</value>
141-
</data>
142-
<data name="InstallCommandDefinition" xml:space="preserve">
143-
<value>Add item to development environment.</value>
144-
</data>
145-
<data name="InstallFailedNuget" xml:space="preserve">
146-
<value>Install failed. Failed to download package:
147-
NuGet returned:
148-
149-
{0}</value>
150-
</data>
151-
<data name="InstallFailedPackage" xml:space="preserve">
152-
<value>Install failed. The settings file in the tool's NuGet package is not valid. Please contact the owner of the NuGet package.
153-
The error was:
154-
155-
{0}</value>
156-
</data>
157120
<data name="InstallFullCommandNameLocalized" xml:space="preserve">
158-
<value>NetInstallCommand</value>
159-
</data>
160-
<data name="InstallToolCommandDefinition" xml:space="preserve">
161-
<value>Install tool for use on the command line.</value>
162-
</data>
163-
<data name="InstallToolConfigfileDefinition" xml:space="preserve">
164-
<value>NuGet configuration file</value>
165-
</data>
166-
<data name="InstallToolFrameworkDefinition" xml:space="preserve">
167-
<value>Target framework to publish for. The target framework has to be specified in the project file.</value>
168-
</data>
169-
<data name="InstallToolPackageIdDefinition" xml:space="preserve">
170-
<value>Package Id in NuGet</value>
121+
<value>.NET Install Command</value>
171122
</data>
172-
<data name="InstallToolVersionDefinition" xml:space="preserve">
173-
<value>Version of the package in NuGet</value>
123+
<data name="CommandDescription" xml:space="preserve">
124+
<value>Installs an item into the development environment.</value>
174125
</data>
175126
</root>

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

+8-8
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
33

44
using Microsoft.DotNet.Cli.CommandLine;
5-
using LocalizableStrings = Microsoft.DotNet.Tools.Install.LocalizableStrings;
5+
using LocalizableStrings = Microsoft.DotNet.Tools.Install.Tool.LocalizableStrings;
66

77
namespace Microsoft.DotNet.Cli
88
{
@@ -11,17 +11,17 @@ internal static class InstallToolCommandParser
1111
public static Command InstallTool()
1212
{
1313
return Create.Command("tool",
14-
LocalizableStrings.InstallToolCommandDefinition,
15-
Accept.ExactlyOneArgument(o => "packageId")
16-
.With(name: "packageId",
17-
description: LocalizableStrings.InstallToolPackageIdDefinition),
14+
LocalizableStrings.CommandDescription,
15+
Accept.ExactlyOneArgument(errorMessage: o => LocalizableStrings.SpecifyExactlyOnePackageId)
16+
.With(name: LocalizableStrings.PackageIdArgumentName,
17+
description: LocalizableStrings.PackageIdArgumentDescription),
1818
Create.Option(
1919
"--version",
20-
LocalizableStrings.InstallToolVersionDefinition,
20+
LocalizableStrings.VersionOptionDescription,
2121
Accept.ExactlyOneArgument()),
2222
Create.Option(
2323
"--configfile",
24-
LocalizableStrings.InstallToolConfigfileDefinition,
24+
LocalizableStrings.ConfigFileOptionDescription,
2525
Accept.ExactlyOneArgument()),
2626
Create.Option(
2727
"--source",
@@ -30,7 +30,7 @@ public static Command InstallTool()
3030
.With(name: LocalizableStrings.SourceOptionName)),
3131
Create.Option(
3232
"-f|--framework",
33-
LocalizableStrings.InstallToolFrameworkDefinition,
33+
LocalizableStrings.FrameworkOptionDescription,
3434
Accept.ExactlyOneArgument()),
3535
CommonOptions.HelpOption());
3636
}

0 commit comments

Comments
 (0)