nuget-license 3.0.0-alpha.10

This is a prerelease version of nuget-license.
There is a newer version of this package available.
See the version list below for details.
dotnet tool install --global nuget-license --version 3.0.0-alpha.10                
This package contains a .NET tool you can call from the shell/command line.
dotnet new tool-manifest # if you are setting up this repo
dotnet tool install --local nuget-license --version 3.0.0-alpha.10                
This package contains a .NET tool you can call from the shell/command line.
#tool dotnet:?package=nuget-license&version=3.0.0-alpha.10&prerelease                
nuke :add-package nuget-license --version 3.0.0-alpha.10                

Nuget License Utility Build Status NuGet

A .net core tool to print the licenses of a project. This tool supports .NET Core and .NET Standard and .NET Framework Projects.

dotnet-project-licenses tool

Install tool

dotnet tool install --global dotnet-project-licenses

Uninstall tool

dotnet tool uninstall --global dotnet-project-licenses

Usage

Usage: dotnet-project-licenses [options]

Options:

Option Description
-i, --input Project or Solution to be analyzed
-ji, --json-input Similar to -i, --input but providing a file containing a valid JSON Array that contains all projects to be analyzed
-t, --include-transitive When set, the analysis includes transitive packages (dependencies of packages that are directly installed to the project)
-a, --allowed-license-types File containing all allowed licenses in JSON format. If omitted, all licenses are considered to be allowed.
-ignore, --ignored-packages File containing a JSON formatted array containing package names, that should be ignored when validating licenses. Package names specified can contain simple Wildcard characters (*) which are used to match any number of characters. Note that even though a package is ignored, it's transitive dependencies are still validated. This Option is useful e.g. to exclude homegrown nuget packages from validation.
-include-ignored, --include-ignored-packages This flag allows to explicitly include ignored packages in the output. licenses.
-mapping, --licenseurl-to-license-mappings When used, this option allows to override the url to license mapping built into the application (see here)
-override, --override-package-information When used, this option allows to override the package information used for the validation. This makes sure that no attempt is made to get the associated information about the package from the available web resources. This is useful for packages that e.g. provide a license file as part of the nuget package which (at the time of writing) cannot be used for validation and thus requires the package's information to be provided by this option.
-d, --license-information-download-location When used, this option downloads the html content of the license URL to the specified folder. This is done for all NuGet packages that specify a license URL instead of providing the license expression.
-o, --output This Parameter accepts the value table, json or jsonPretty. It allows to select the type of output that should be given. If omitted, the output is given in tabular form.
-err, --error-only This flag allows to print only packages that contain validation errors (if there are any). This allows the user to focus on errors instead of having to deal with many properly validated licenses.

Example tool commands

Show help

dotnet-project-licenses --help

Validate licenses for .csproj file

dotnet-project-licenses -i project.csproj

Generate machine readable output

dotnet-project-licenses -i project.csproj -o jsonPretty

Docker

Build the image

docker build . -t nuget-license

Run the same example commands as above in docker

docker run -it -v projectPath:/tmp nuget-license --help
docker run -it -v projectPath:/tmp nuget-license -i /tmp/project.csproj
Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 is compatible.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

Version Downloads Last updated
3.0.13 36,368 9/18/2024
3.0.12 889 9/16/2024
3.0.11 142 9/16/2024
3.0.10 3,190 9/4/2024
3.0.9 12,668 8/15/2024
3.0.9-beta.3 64 8/14/2024
3.0.9-beta.2 65 8/14/2024
3.0.9-beta.1 61 8/14/2024
3.0.8 1,748 8/12/2024
3.0.7 769 8/7/2024
3.0.6 1,947 7/25/2024
3.0.5 5,255 7/10/2024
3.0.4 1,583 7/4/2024
3.0.3 19,911 4/9/2024
3.0.3-beta.4 2,384 3/4/2024
3.0.3-beta.3 83 2/27/2024
3.0.2 6,233 2/20/2024
3.0.1 6,775 1/8/2024
3.0.0 323 12/9/2023
3.0.0-alpha.10 87 12/9/2023