Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ


Choose your language

InfoQ Homepage News NuGet 6.9 Released: dotnet Search Command Support and Visual Studio UI Multitargeting

NuGet 6.9 Released: dotnet Search Command Support and Visual Studio UI Multitargeting

In the latest release of NuGet version 6.9, developers can expect several new features and bug fixes which have been introduced. Among the key additions are enhancements to the multi-targeting experience within Visual Studio, and the incorporation of support for the dotnet search command.

The most notable feature of NuGet 6.9 is the way how users can now employ the dotnet package search command via the nuget.exe CLI interface. This feature can be used to explore one or multiple package sources for packages that match a specified search term.

(Word searched across all sources present in the nuget.config file, Source: Announcing NuGet 6.9)

As reported, if no specific sources are designated, all sources are defined within the nuget.config will be utilized. Furthermore, users can list all available versions for a particular package. The command format follows the structure of dotnet package search [search term] [options].

Furthermore, a range of options is available to aid in refining search results, including the –take and –skip parameters. Developers can specify the desired source of the search operation by utilizing the –source option. Additionally, the –exact-match option allows for the restriction of available package versions. Further customization of output rendering can be achieved through the –verbosity and –format options.

In the realm of Visual Studio, NuGet 6.9 brings about notable improvements to managing packages for multitargeted projects. In instances where a package is conditionally installed across multiple frameworks within a multitargeted project, conditional updates will now extend across all conditions. Moreover, users can now uninstall conditionally installed packages directly from within the Visual Studio interface.

Based on the release post, the 6.9 version is also focused on bug fixes and some of them are related to NuGetAudit and fixes for downloading the vulnerabilities database when a project doesn't use any packages, also for preventing static graph-based restore from unnecessarily enumerating every item's metadata, migrating NuGet.CommandLine.XPlat package search to utilize System.CommandLine, and setting NuGetAudit defaults in MSBuild.

Other fixed issues encompass allowing floating versions with Central Package Management (CPM), resolving a bug where Static Graph restore wouldn't warn for invalid projects, renaming no-cache to no-http-cache, fixing the vulnerability indicator showing up on dependent projects, addressing a performance issue in AssetsFileDependenciesDataSource, and several more which could be found by readers exploring the official release post.

The NuGet team emphasises and states the gratitude forward a very active community contribution in this release:

On behalf of the NuGet team and the entire .NET community, we’d like to express our sincere gratitude to all the community contributors who have generously given their time and expertise to improve NuGet this release. Thank you.

Lastly, the NuGet 6.9 version is already included in the Visual Studio 2022 edition, and .NET 8.0 is out of the box. Interested developers can also download NuGet 6.9 for Windows, macOS, and Linux as a standalone executable.

About the Author

Rate this Article