seesharper / dotnet-deps

A simple command line (.Net Global tool) to inspect and update dependencies

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

dotnet-deps

A simple command line global tool to list and update NuGet dependencies.

Managing dependencies and making sure they are up to date can be a challenge sometimes. dotnet-deps a simple tool that makes it easy both to analyze and update our NuGet dependencies.

Installing

dotnet tool install -g dotnet-deps

Get Started

Open a terminal window and navigate to the directory that contains the project(s) we want to analyze.

deps
/Users/bernhardrichter/GitHub/dotnet-deps/src/Dotnet.Deps/Dotnet.Deps.csproj                                            
McMaster.Extensions.CommandLineUtils 2.5.1 => 2.6.0 (nuget.org) ๐Ÿ˜ข
NuGet.Configuration 5.4.0 5.4.0 (nuget.org) ๐Ÿบ
NuGet.Packaging 5.4.0 5.4.0 (nuget.org) ๐Ÿบ
NuGet.Packaging.Core 5.4.0 5.4.0 (nuget.org) ๐Ÿบ
simpleexec 6.2.0 6.2.0 (nuget.org) ๐Ÿบ

The output is quite simple. We get a ๐Ÿบ for every dependency that is up-to-date and a ๐Ÿ˜ข for all dependencies that needs to be updated.

If we should want to update all dependencies we can simply use the update option.

deps --update

Filtering

We can filter the packages to be processed by dotnet-deps by passing a --filter option.

deps --filter McMaster

The filter is applied as an regular expression

Exit Code

If all packages are up-to-date, dotnet-deps will exit with exit code 0, otherwise 0xbad

Project file types

The following file types are supported by dotnet-deps

  • SDK-style csproj files (*.csproj)

  • MsBuild props files (*.props)

  • MsBuild target files (*.target)

  • C# script files (*.csx)

  • NuGet metadata files (*.nuspec)

dotnet-deps only looks for <PackageReference> nodes and WILL NOT try to resolve MSBuild variables.

About

A simple command line (.Net Global tool) to inspect and update dependencies


Languages

Language:C# 100.0%