diff --git a/src/dotnet/CommonLocalizableStrings.resx b/src/dotnet/CommonLocalizableStrings.resx index 4b8c4d0c5..967e72914 100644 --- a/src/dotnet/CommonLocalizableStrings.resx +++ b/src/dotnet/CommonLocalizableStrings.resx @@ -647,7 +647,7 @@ setx PATH "%PATH%;{0}" VERSION_SUFFIX - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. PROJECT | SOLUTION diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/ListPackageReferencesCommand.cs b/src/dotnet/commands/dotnet-list/dotnet-list-package/ListPackageReferencesCommand.cs index f3cafd3a9..6ac1f8866 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/ListPackageReferencesCommand.cs +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/ListPackageReferencesCommand.cs @@ -7,6 +7,7 @@ using System.IO; using System.Linq; using Microsoft.DotNet.Cli; using Microsoft.DotNet.Cli.CommandLine; +using Microsoft.DotNet.Cli.Utils; using Microsoft.DotNet.Tools.Common; using Microsoft.DotNet.Tools.NuGet; @@ -27,25 +28,15 @@ namespace Microsoft.DotNet.Tools.List.PackageReferences throw new ArgumentNullException(nameof(appliedCommand)); } - // Gets the absolute path of the given path _fileOrDirectory = PathUtility.GetAbsolutePath(PathUtility.EnsureTrailingSlash(Directory.GetCurrentDirectory()), appliedCommand.Arguments.Single()); - FileAttributes attr = File.GetAttributes(_fileOrDirectory); - - if (attr.HasFlag(FileAttributes.Directory)) - { - _fileOrDirectory = PathUtility.EnsureTrailingSlash(_fileOrDirectory); - } - _appliedCommand = appliedCommand["package"]; } public override int Execute() { - var result = NuGetCommand.Run(TransformArgs()); - - return result; + return NuGetCommand.Run(TransformArgs()); } private string[] TransformArgs() @@ -58,63 +49,31 @@ namespace Microsoft.DotNet.Tools.List.PackageReferences args.Add(GetProjectOrSolution()); - if (_appliedCommand.HasOption("outdated")) - { - args.Add("--outdated"); - } - - if (_appliedCommand.HasOption("include-transitive")) - { - args.Add("--include-transitive"); - } - - if (_appliedCommand.HasOption("framework")) - { - //Forward framework as multiple flags - foreach (var framework in _appliedCommand.AppliedOptions["framework"].Arguments) - { - args.Add("--framework"); - args.Add(framework); - } - } + args.AddRange(_appliedCommand.OptionValuesToBeForwarded()); if (_appliedCommand.HasOption("include-prerelease")) { CheckForOutdated("--include-prerelease"); - args.Add("--include-prerelease"); } if (_appliedCommand.HasOption("highest-patch")) { CheckForOutdated("--highest-patch"); - args.Add("--highest-patch"); } if (_appliedCommand.HasOption("highest-minor")) { CheckForOutdated("--highest-minor"); - args.Add("--highest-minor"); } if (_appliedCommand.HasOption("config")) { CheckForOutdated("--config"); - args.Add("--config"); - //Config path absolute path - var configPath = PathUtility.GetAbsolutePath(PathUtility.EnsureTrailingSlash(Directory.GetCurrentDirectory()), - _appliedCommand.AppliedOptions["config"].Arguments.Single()); - args.Add(configPath); } if (_appliedCommand.HasOption("source")) { CheckForOutdated("--source"); - //Forward source as multiple flags - foreach (var source in _appliedCommand.AppliedOptions["source"].Arguments) - { - args.Add("--source"); - args.Add(source); - } } return args.ToArray(); @@ -129,7 +88,7 @@ namespace Microsoft.DotNet.Tools.List.PackageReferences { if (!_appliedCommand.HasOption("outdated")) { - throw new Exception(string.Format(LocalizableStrings.OutdatedOptionOnly, option)); + throw new GracefulException(LocalizableStrings.OutdatedOptionOnly, option); } @@ -144,16 +103,15 @@ namespace Microsoft.DotNet.Tools.List.PackageReferences private string GetProjectOrSolution() { string resultPath = _fileOrDirectory; - FileAttributes attr = File.GetAttributes(resultPath); - if (attr.HasFlag(FileAttributes.Directory)) + if (Directory.Exists(resultPath)) { var possibleSolutionPath = Directory.GetFiles(resultPath, "*.sln", SearchOption.TopDirectoryOnly); //If more than a single sln file is found, an error is thrown since we can't determine which one to choose. if (possibleSolutionPath.Count() > 1) { - throw new Exception(LocalizableStrings.MultipleSolutionsFound + Environment.NewLine + string.Join(Environment.NewLine, possibleSolutionPath.ToArray())); + throw new GracefulException(CommonLocalizableStrings.MoreThanOneSolutionInDirectory, resultPath); } //If a single solution is found, use it. else if (possibleSolutionPath.Count() == 1) @@ -170,7 +128,7 @@ namespace Microsoft.DotNet.Tools.List.PackageReferences //No projects found throws an error that no sln nor projs were found if (possibleProjectPath.Count() == 0) { - throw new Exception(LocalizableStrings.NoProjectsOrSolutions); + throw new GracefulException(LocalizableStrings.NoProjectsOrSolutions, resultPath); } //A single project found, use it else if (possibleProjectPath.Count() == 1) @@ -180,15 +138,14 @@ namespace Microsoft.DotNet.Tools.List.PackageReferences //More than one project found. Not sure which one to choose else { - throw new Exception(LocalizableStrings.MultipleProjectsFound + Environment.NewLine + string.Join(Environment.NewLine, possibleProjectPath.ToArray())); + throw new GracefulException(CommonLocalizableStrings.MoreThanOneProjectInDirectory, resultPath); } } } - //Make sure the file exists if (!File.Exists(resultPath)) { - throw new FileNotFoundException(LocalizableStrings.FileNotFound, resultPath); + throw new GracefulException(LocalizableStrings.FileNotFound, resultPath); } return resultPath; diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/ListPackageReferencesCommandParser.cs b/src/dotnet/commands/dotnet-list/dotnet-list-package/ListPackageReferencesCommandParser.cs index 803dd014c..b273db472 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/ListPackageReferencesCommandParser.cs +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/ListPackageReferencesCommandParser.cs @@ -1,6 +1,7 @@ // Copyright (c) .NET Foundation and contributors. All rights reserved. // Licensed under the MIT license. See LICENSE file in the project root for full license information. +using System.Collections.Generic; using System.Linq; using Microsoft.DotNet.Cli.CommandLine; using LocalizableStrings = Microsoft.DotNet.Tools.List.PackageReferences.LocalizableStrings; @@ -12,32 +13,46 @@ namespace Microsoft.DotNet.Cli public static Command ListPackageReferences() => Create.Command( "package", LocalizableStrings.AppFullName, - Accept.ZeroOrOneArgument(), + Accept.NoArguments(), CommonOptions.HelpOption(), Create.Option("--outdated", - LocalizableStrings.CmdOutdatedDescription), + LocalizableStrings.CmdOutdatedDescription, + Accept.NoArguments().ForwardAs("--outdated")), Create.Option("--framework", LocalizableStrings.CmdFrameworkDescription, Accept.OneOrMoreArguments() .With(name: LocalizableStrings.CmdFramework) - .ForwardAsSingle(o => $"--framework {string.Join("%3B", o.Arguments)}")), + .ForwardAsMany(o => ForwardedArguments("--framework", o.Arguments))), Create.Option("--include-transitive", - LocalizableStrings.CmdTransitiveDescription), + LocalizableStrings.CmdTransitiveDescription, + Accept.NoArguments().ForwardAs("--include-transitive")), Create.Option("--include-prerelease", - LocalizableStrings.CmdPrereleaseDescription), + LocalizableStrings.CmdPrereleaseDescription, + Accept.NoArguments().ForwardAs("--include-prerelease")), Create.Option("--highest-patch", - LocalizableStrings.CmdHighestPatchDescription), + LocalizableStrings.CmdHighestPatchDescription, + Accept.NoArguments().ForwardAs("--highest-patch")), Create.Option("--highest-minor", - LocalizableStrings.CmdHighestMinorDescription), + LocalizableStrings.CmdHighestMinorDescription, + Accept.NoArguments().ForwardAs("--highest-minor")), Create.Option("--config", LocalizableStrings.CmdConfigDescription, Accept.ExactlyOneArgument() .With(name: LocalizableStrings.CmdConfig) - .ForwardAsSingle(o => $"--config {o.Arguments.Single()}")), + .ForwardAsMany(o => new [] { "--config", o.Arguments.Single() })), Create.Option("--source", LocalizableStrings.CmdSourceDescription, Accept.OneOrMoreArguments() .With(name: LocalizableStrings.CmdSource) - .ForwardAsSingle(o => $"--source {string.Join("%3B", o.Arguments)}"))); + .ForwardAsMany(o => ForwardedArguments("--source", o.Arguments)))); + + private static IEnumerable ForwardedArguments(string token, IEnumerable arguments) + { + foreach (var arg in arguments) + { + yield return token; + yield return arg; + } + } } } diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/LocalizableStrings.resx b/src/dotnet/commands/dotnet-list/dotnet-list-package/LocalizableStrings.resx index 4d431c4ba..4726d960e 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/LocalizableStrings.resx +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/LocalizableStrings.resx @@ -118,7 +118,7 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - List all packages references of the project. + List all package references of the project or solution. FRAMEWORK | FRAMEWORK\RID @@ -132,40 +132,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - - - The directory given includes multiple solutions. Please specify one of the following solutions: - - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. SOURCE - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.cs.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.cs.xlf index fb06f3036..b650b4dda 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.cs.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.cs.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. Zobrazí všechny odkazy mezi projekty v projektu. @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.de.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.de.xlf index 59c58ea0c..d4488607f 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.de.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.de.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. Hiermit listen Sie alle Projekt-zu-Projekt-Verweise des Projekts auf. @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.es.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.es.xlf index 0a97198ce..a02426371 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.es.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.es.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. Enumera referencias de proyecto a proyecto del proyecto. @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.fr.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.fr.xlf index 29d8b06a7..6b56420a8 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.fr.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.fr.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. Listez toutes les références projet à projet du projet. @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.it.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.it.xlf index c94dd796c..d59cadcac 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.it.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.it.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. Elenca tutti i riferimenti P2P (da progetto a progetto) del progetto. @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.ja.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.ja.xlf index a574a856f..77ca49f69 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.ja.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.ja.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. プロジェクトのすべてのプロジェクト間参照をリストします。 @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.ko.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.ko.xlf index b87e499c6..89f428b61 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.ko.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.ko.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. 프로젝트의 모든 프로젝트 간 참조를 나열합니다. @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.pl.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.pl.xlf index 92aa3f78b..d16a26728 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.pl.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.pl.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. Wyświetl listę wszystkich odwołań między projektami w projekcie. @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.pt-BR.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.pt-BR.xlf index 145a38558..ed902a9ba 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.pt-BR.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.pt-BR.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. Listar todas as referências de projeto a projeto do projeto. @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.ru.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.ru.xlf index e7f5e8ef1..a98f7b680 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.ru.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.ru.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. Вывод списка всех ссылок из одного проекта на другой. @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.tr.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.tr.xlf index 0b303a0e8..c8d7503d5 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.tr.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.tr.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. Projenin tüm projeden projeye başvurularını listeleyin. @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.zh-Hans.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.zh-Hans.xlf index 73e8bb9a3..7471c4f3a 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.zh-Hans.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.zh-Hans.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. 列出项目的所有项目到项目引用。 @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.zh-Hant.xlf b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.zh-Hant.xlf index 65f66aaaa..9abbfc884 100644 --- a/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.zh-Hant.xlf +++ b/src/dotnet/commands/dotnet-list/dotnet-list-package/xlf/LocalizableStrings.zh-Hant.xlf @@ -3,7 +3,7 @@ - List all packages references of the project. + List all package references of the project or solution. 列出專案的所有專案對專案參考。 @@ -27,44 +27,34 @@ Lists transitive and top-level packages. - - The directory given includes multiple projects. Please specify one of the following projects: - The directory given includes multiple projects. Please specify one of the following projects: - - - - The directory given includes multiple solutions. Please specify one of the following solutions: - The directory given includes multiple solutions. Please specify one of the following solutions: - - - The given directory does not include any solution or project. - The given directory does not include any solution or project. + A project or solution file could not be found in {0}. Specify a project or solution file to use. + A project or solution file could not be found in {0}. Specify a project or solution file to use. - CONFIG FILE - CONFIG FILE + CONFIG_FILE + CONFIG_FILE - A path to a config file to specify sources. Works only with `--outdated`. - A path to a config file to specify sources. Works only with `--outdated`. + The path to the NuGet config file to use. Requires the '--outdated' option. + The path to the NuGet config file to use. Requires the '--outdated' option. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major version number when searching for newer packages. Requires the '--outdated' option. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. - Considers only the versions that have matching minor and major when looking for latest version. Works only with `--outdated`. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. + Consider only the packages with a matching major and minor version numbers when searching for newer packages. Requires the '--outdated' option. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. - Considers prerelease versions when looking for latest version. Works only with `--outdated`. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. + Consider packages with prerelease versions when searching for newer packages. Requires the '--outdated' option. @@ -73,20 +63,20 @@ - Sources to lookup for latest versions. Works only with `--outdated`. - Sources to lookup for latest versions. Works only with `--outdated`. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. + The NuGet sources to use when searching for newer packages. Requires the '--outdated' option. - This option `{0}` can only be used with `--outdated` present. - This option `{0}` can only be used with `--outdated` present. + Option '{0}' requires the '--outdated' option to be specified. + Option '{0}' requires the '--outdated' option to be specified. - The given file was not found. Please make sure that you are passing the correct path. - The given file was not found. Please make sure that you are passing the correct path. + Could not find file or directory '{0}'. + Could not find file or directory '{0}'. - \ No newline at end of file + diff --git a/src/dotnet/xlf/CommonLocalizableStrings.cs.xlf b/src/dotnet/xlf/CommonLocalizableStrings.cs.xlf index 5ab5ea5ad..6f2fceab0 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.cs.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.cs.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. @@ -905,4 +905,4 @@ setx PATH "%PATH%;{0}" - \ No newline at end of file + diff --git a/src/dotnet/xlf/CommonLocalizableStrings.de.xlf b/src/dotnet/xlf/CommonLocalizableStrings.de.xlf index ea51e81a0..38b4f5eb5 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.de.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.de.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. @@ -905,4 +905,4 @@ setx PATH "%PATH%;{0}" - \ No newline at end of file + diff --git a/src/dotnet/xlf/CommonLocalizableStrings.es.xlf b/src/dotnet/xlf/CommonLocalizableStrings.es.xlf index 300cb039e..bc995bcb0 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.es.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.es.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. diff --git a/src/dotnet/xlf/CommonLocalizableStrings.fr.xlf b/src/dotnet/xlf/CommonLocalizableStrings.fr.xlf index c8f9eda0e..6546b6413 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.fr.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.fr.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. diff --git a/src/dotnet/xlf/CommonLocalizableStrings.it.xlf b/src/dotnet/xlf/CommonLocalizableStrings.it.xlf index 64fa8d1f8..6463ac8a0 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.it.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.it.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. diff --git a/src/dotnet/xlf/CommonLocalizableStrings.ja.xlf b/src/dotnet/xlf/CommonLocalizableStrings.ja.xlf index 4b66cdf0b..615af95a9 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.ja.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.ja.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. diff --git a/src/dotnet/xlf/CommonLocalizableStrings.ko.xlf b/src/dotnet/xlf/CommonLocalizableStrings.ko.xlf index 0d2454ef5..7062fdb43 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.ko.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.ko.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. diff --git a/src/dotnet/xlf/CommonLocalizableStrings.pl.xlf b/src/dotnet/xlf/CommonLocalizableStrings.pl.xlf index d35e9ecf5..d7adf7323 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.pl.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.pl.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. diff --git a/src/dotnet/xlf/CommonLocalizableStrings.pt-BR.xlf b/src/dotnet/xlf/CommonLocalizableStrings.pt-BR.xlf index ae24edce1..1bac8d564 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.pt-BR.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.pt-BR.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. diff --git a/src/dotnet/xlf/CommonLocalizableStrings.ru.xlf b/src/dotnet/xlf/CommonLocalizableStrings.ru.xlf index 0aef6105a..6d54fb08f 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.ru.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.ru.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. diff --git a/src/dotnet/xlf/CommonLocalizableStrings.tr.xlf b/src/dotnet/xlf/CommonLocalizableStrings.tr.xlf index 7e3c0c27a..050190c04 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.tr.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.tr.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. diff --git a/src/dotnet/xlf/CommonLocalizableStrings.zh-Hans.xlf b/src/dotnet/xlf/CommonLocalizableStrings.zh-Hans.xlf index 4bc3bd612..bacdb9138 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.zh-Hans.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.zh-Hans.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. diff --git a/src/dotnet/xlf/CommonLocalizableStrings.zh-Hant.xlf b/src/dotnet/xlf/CommonLocalizableStrings.zh-Hant.xlf index 364d5199d..3c7fd9ece 100644 --- a/src/dotnet/xlf/CommonLocalizableStrings.zh-Hant.xlf +++ b/src/dotnet/xlf/CommonLocalizableStrings.zh-Hant.xlf @@ -894,8 +894,8 @@ setx PATH "%PATH%;{0}" - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. - The project (or solution only with package command) file to operate on. If a file is not specified, the command will search the current directory for a (solution if used with package command then a) project. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. diff --git a/test/Microsoft.DotNet.Cli.Tests.sln b/test/Microsoft.DotNet.Cli.Tests.sln index c1ce1757e..2667b081f 100644 --- a/test/Microsoft.DotNet.Cli.Tests.sln +++ b/test/Microsoft.DotNet.Cli.Tests.sln @@ -93,6 +93,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "dotnet-install-tool.Tests", EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "InsertionTests", "InsertionTests\InsertionTests.csproj", "{A9713391-3D44-4664-9C41-75765218FD6C}" EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "dotnet-list-package.Tests", "dotnet-list-package.Tests\dotnet-list-package.Tests.csproj", "{377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -607,6 +609,18 @@ Global {A9713391-3D44-4664-9C41-75765218FD6C}.Release|x64.Build.0 = Release|Any CPU {A9713391-3D44-4664-9C41-75765218FD6C}.Release|x86.ActiveCfg = Release|Any CPU {A9713391-3D44-4664-9C41-75765218FD6C}.Release|x86.Build.0 = Release|Any CPU + {377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}.Debug|Any CPU.Build.0 = Debug|Any CPU + {377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}.Debug|x64.ActiveCfg = Debug|Any CPU + {377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}.Debug|x64.Build.0 = Debug|Any CPU + {377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}.Debug|x86.ActiveCfg = Debug|Any CPU + {377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}.Debug|x86.Build.0 = Debug|Any CPU + {377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}.Release|Any CPU.ActiveCfg = Release|Any CPU + {377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}.Release|Any CPU.Build.0 = Release|Any CPU + {377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}.Release|x64.ActiveCfg = Release|Any CPU + {377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}.Release|x64.Build.0 = Release|Any CPU + {377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}.Release|x86.ActiveCfg = Release|Any CPU + {377363FE-0B87-4ACB-AEF3-3FF6454EC8D4}.Release|x86.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/test/dotnet-list-package.Tests/GivenDotnetListPackage.cs b/test/dotnet-list-package.Tests/GivenDotnetListPackage.cs index 03fc999ea..8fbfcf51c 100644 --- a/test/dotnet-list-package.Tests/GivenDotnetListPackage.cs +++ b/test/dotnet-list-package.Tests/GivenDotnetListPackage.cs @@ -36,11 +36,11 @@ namespace Microsoft.DotNet.Cli.List.Package.Tests cmd.Should().Pass(); new RestoreCommand() - .WithWorkingDirectory(projectDirectory) - .Execute() - .Should() - .Pass() - .And.NotHaveStdErr(); + .WithWorkingDirectory(projectDirectory) + .Execute() + .Should() + .Pass() + .And.NotHaveStdErr(); new ListPackageCommand() .WithPath(projectDirectory) @@ -52,7 +52,7 @@ namespace Microsoft.DotNet.Cli.List.Package.Tests } [Fact] - public void AutoReferencedPackages() + public void ItListsAutoReferencedPackages() { var testAsset = "TestAppSimple"; var projectDirectory = TestAssets @@ -63,11 +63,11 @@ namespace Microsoft.DotNet.Cli.List.Package.Tests .FullName; new RestoreCommand() - .WithWorkingDirectory(projectDirectory) - .Execute() - .Should() - .Pass() - .And.NotHaveStdErr(); + .WithWorkingDirectory(projectDirectory) + .Execute() + .Should() + .Pass() + .And.NotHaveStdErr(); new ListPackageCommand() .WithPath(projectDirectory) @@ -80,7 +80,7 @@ namespace Microsoft.DotNet.Cli.List.Package.Tests } [Fact] - public void RunOnSolution() + public void ItRunOnSolution() { var sln = "TestAppWithSlnAndSolutionFolders"; var projectDirectory = TestAssets @@ -91,11 +91,11 @@ namespace Microsoft.DotNet.Cli.List.Package.Tests .FullName; new RestoreCommand() - .WithWorkingDirectory(projectDirectory) - .Execute() - .Should() - .Pass() - .And.NotHaveStdErr(); + .WithWorkingDirectory(projectDirectory) + .Execute() + .Should() + .Pass() + .And.NotHaveStdErr(); new ListPackageCommand() .WithPath(projectDirectory) @@ -126,7 +126,7 @@ namespace Microsoft.DotNet.Cli.List.Package.Tests } [Fact] - public void TransitivePackagePrinted() + public void ItListsTransitivePackage() { var testAsset = "NewtonSoftDependentProject"; var projectDirectory = TestAssets @@ -137,11 +137,11 @@ namespace Microsoft.DotNet.Cli.List.Package.Tests .FullName; new RestoreCommand() - .WithWorkingDirectory(projectDirectory) - .Execute() - .Should() - .Pass() - .And.NotHaveStdErr(); + .WithWorkingDirectory(projectDirectory) + .Execute() + .Should() + .Pass() + .And.NotHaveStdErr(); new ListPackageCommand() .WithPath(projectDirectory) @@ -161,13 +161,13 @@ namespace Microsoft.DotNet.Cli.List.Package.Tests } [Theory] - [InlineData("", "[.NETFramework,Version=v4.5.1]", null)] - [InlineData("", "[.NETCoreApp,Version=v2.2]", null)] - [InlineData("--framework netcoreapp2.2 --framework net451", "[.NETFramework,Version=v4.5.1]", null)] - [InlineData("--framework netcoreapp2.2 --framework net451", "[.NETCoreApp,Version=v2.2]", null)] - [InlineData("--framework netcoreapp2.2", "[.NETCoreApp,Version=v2.2]", "[.NETFramework,Version=v4.5.1]")] - [InlineData("--framework net451", "[.NETFramework,Version=v4.5.1]", "[.NETCoreApp,Version=v2.2]")] - public void FrameworkSpecificList_Success(string args, string shouldInclude, string shouldntInclude) + [InlineData("", "[net451]", null)] + [InlineData("", "[netcoreapp2.2]", null)] + [InlineData("--framework netcoreapp2.2 --framework net451", "[net451]", null)] + [InlineData("--framework netcoreapp2.2 --framework net451", "[netcoreapp2.2]", null)] + [InlineData("--framework netcoreapp2.2", "[netcoreapp2.2]", "[net451]")] + [InlineData("--framework net451", "[net451]", "[netcoreapp2.2]")] + public void ItListsValidFrameworks(string args, string shouldInclude, string shouldntInclude) { var testAsset = "MSBuildAppWithMultipleFrameworks"; var projectDirectory = TestAssets @@ -178,38 +178,38 @@ namespace Microsoft.DotNet.Cli.List.Package.Tests .FullName; new RestoreCommand() - .WithWorkingDirectory(projectDirectory) - .Execute() - .Should() - .Pass() - .And.NotHaveStdErr(); + .WithWorkingDirectory(projectDirectory) + .Execute() + .Should() + .Pass() + .And.NotHaveStdErr(); if (shouldntInclude == null) { new ListPackageCommand() - .WithPath(projectDirectory) - .Execute(args) - .Should() - .Pass() - .And.NotHaveStdErr() - .And.HaveStdOutContainingIgnoreSpaces(shouldInclude.Replace(" ", "")); + .WithPath(projectDirectory) + .Execute(args) + .Should() + .Pass() + .And.NotHaveStdErr() + .And.HaveStdOutContainingIgnoreSpaces(shouldInclude.Replace(" ", "")); } else { new ListPackageCommand() - .WithPath(projectDirectory) - .Execute(args) - .Should() - .Pass() - .And.NotHaveStdErr() - .And.HaveStdOutContainingIgnoreSpaces(shouldInclude.Replace(" ", "")) - .And.NotHaveStdOutContaining(shouldntInclude.Replace(" ", "")); + .WithPath(projectDirectory) + .Execute(args) + .Should() + .Pass() + .And.NotHaveStdErr() + .And.HaveStdOutContainingIgnoreSpaces(shouldInclude.Replace(" ", "")) + .And.NotHaveStdOutContaining(shouldntInclude.Replace(" ", "")); } } [Fact] - public void FrameworkSpecificList_Fail() + public void ItDoesNotAcceptInvalidFramework() { var testAsset = "MSBuildAppWithMultipleFrameworks"; var projectDirectory = TestAssets @@ -220,20 +220,20 @@ namespace Microsoft.DotNet.Cli.List.Package.Tests .FullName; new RestoreCommand() - .WithWorkingDirectory(projectDirectory) - .Execute() - .Should() - .Pass(); + .WithWorkingDirectory(projectDirectory) + .Execute() + .Should() + .Pass(); new ListPackageCommand() - .WithPath(projectDirectory) - .Execute("--framework invalid") - .Should() - .Fail(); + .WithPath(projectDirectory) + .Execute("--framework invalid") + .Should() + .Fail(); } [Fact] - public void FSharpProject() + public void ItListsFSharpProject() { var testAsset = "FSharpTestAppSimple"; var projectDirectory = TestAssets @@ -244,11 +244,11 @@ namespace Microsoft.DotNet.Cli.List.Package.Tests .FullName; new RestoreCommand() - .WithWorkingDirectory(projectDirectory) - .Execute() - .Should() - .Pass() - .And.NotHaveStdErr(); + .WithWorkingDirectory(projectDirectory) + .Execute() + .Should() + .Pass() + .And.NotHaveStdErr(); new ListPackageCommand() .WithPath(projectDirectory) diff --git a/test/dotnet-list-package.Tests/MSBuild.exe b/test/dotnet-list-package.Tests/MSBuild.exe deleted file mode 100644 index 2b4d0f999..000000000 --- a/test/dotnet-list-package.Tests/MSBuild.exe +++ /dev/null @@ -1 +0,0 @@ -https://github.com/Microsoft/msbuild/issues/927 \ No newline at end of file diff --git a/test/dotnet-list-package.Tests/MSBuild.exe.config b/test/dotnet-list-package.Tests/MSBuild.exe.config deleted file mode 100644 index 2b4d0f999..000000000 --- a/test/dotnet-list-package.Tests/MSBuild.exe.config +++ /dev/null @@ -1 +0,0 @@ -https://github.com/Microsoft/msbuild/issues/927 \ No newline at end of file diff --git a/test/dotnet-list-reference.Tests/GivenDotnetListReference.cs b/test/dotnet-list-reference.Tests/GivenDotnetListReference.cs index 3590c57a2..9fd455460 100644 --- a/test/dotnet-list-reference.Tests/GivenDotnetListReference.cs +++ b/test/dotnet-list-reference.Tests/GivenDotnetListReference.cs @@ -14,23 +14,24 @@ namespace Microsoft.DotNet.Cli.List.Reference.Tests { public class GivenDotnetListReference : TestBase { - private const string HelpText = @"Usage: dotnet list reference [options] + private const string HelpText = @"Usage: dotnet list reference [options] Arguments: - The project file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. Options: -h, --help Show command line help."; - private const string ListCommandHelpText = @"Usage: dotnet list [options] [command] + private const string ListCommandHelpText = @"Usage: dotnet list [options] [command] Arguments: - The project file to operate on. If a file is not specified, the command will search the current directory for one. + The project or solution file to operate on. If a file is not specified, the command will search the current directory for one. Options: -h, --help Show command line help. Commands: + package List all package references of the project or solution. reference List all project-to-project references of the project."; const string FrameworkNet451Arg = "-f net451";