LicenseTracker is a library for tracking licenses of dependencies.
- License sources: GitHub and Spdx
- License authorities: NuGet and npm
- License URL providers: NuGet
- License readers: GitHub
- License comparers: Soerensen-Dice
- Write your own license source, authority, url provider, reader and comparer
- Get licenses from GitHub:
var licenseSource = new GitHubLicenseSource();
var licenses = await licenseSource.GetLicensesAsync();
- Get licenses from Spdx:
var licenseSource = new SpdxLicenseSource();
var licenses = await licenseSource.GetLicensesAsync();
- Check license of dependency:
var check = new LicenseCheck();
var licenses = await licenseSource.GetLicensesAsync();
check.AddKnownLicenses(licenses);
check.AddLicenseAuthority(new NuGetLicenseAuthority(check.KnownLicenses));
check.AddLicenseAuthority(new NpmLicenseAuthority(check.KnownLicenses));
var license = await check.ExecuteAsync("Newtonsoft.Json", "11.0.1");
- License icon by beth bolton from The Noun Project