NuGet v3 catalog reader
Switch branches/tags
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.nuget
.vscode
build
src
test
.editorconfig
.gitattributes
.gitignore
.travis.yml
LICENSE
NuGet.CatalogReader.sln
NuGet.Config
README.md
ReleaseNotes.md
appveyor.yml
build.cmd
build.ps1
build.sh

README.md

What are these tools?

NuGetMirror.exe is a command line tool to mirror nuget.org to disk, or any NuGet v3 feed. It supports filtering package ids and wildcards to narrow down the set of mirrored packages.

NuGet.CatalogReader is a library for reading package ids, versions, and the change history of a NuGet v3 feeds or nuget.org.

Getting NuGetMirror

Manually getting nugetmirror.exe (Windows and Mono)

  1. Download the latest nupkg from NuGet.org
  2. Extract tools/NuGetMirror.exe to a local folder and run it.

Install global tool (dotnet CLI >= 2.1.300-preview2)

  1. dotnet tool install -g nugetmirror
  2. nugetmirror should now be on your PATH

Manually run nugetmirror.dll (dotnet CLI cross platform)

  1. Download the latest nupkg from NuGet.org
  2. Extract the nupkg to a local folder
  3. dotnet <PathToNupkg>/tools/netcoreapp2.1/any/NuGetMirror.dll

Build Status

AppVeyor Travis Visual Studio Online
AppVeyor Travis VSO

CI builds

CI builds are located on the following NuGet feed:

https://nuget.blob.core.windows.net/packages/index.json

The list of packages on this feed is here.

Quick start

Using NuGetMirror.exe

Mirror all packages to a folder on disk.

NuGetMirror.exe nupkgs https://api.nuget.org/v3/index.json -o d:\tmp

Using NuGet.CatalogReader

Discover all packages in a feed using GetFlattenedEntriesAsync. To see the complete history including edits use GetEntriesAsync.

var feed = new Uri("https://api.nuget.org/v3/index.json");

using (var catalog = new CatalogReader(feed))
{
    foreach (var entry in await catalog.GetFlattenedEntriesAsync())
    {
        Console.WriteLine($"[{entry.CommitTimeStamp}] {entry.Id} {entry.Version}");
    }
}

Coding

This solution uses .NET Core, get the tools here.

License

MIT License