praeclarum / FuGetGallery

An alternative web UI for browsing nuget packages
https://www.fuget.org
MIT License
683 stars 121 forks source link

Allow for configuration of multiple package sources #61

Closed JustinMoss closed 5 years ago

JustinMoss commented 5 years ago

This adds the ability to configure multiple package sources. This should solve most of what #13 (and the duplicate #50 ) is asking for. This does not currently allow for authenticated sources, but it should be a simple addition of more configuration values and adding them to headers.

Adding a new package source is as simple as adding a new entry in the appsettings.json, under NugetPackageSources. If the NugetPackageSources section is missing completely, it will default to the current nuget.org source.

In order to get this to work with our internal version of Nuget Gallery, I had to add some specific endpoints, because it does not support v3, but anything that does should be able to simply swap out urls.

praeclarum commented 5 years ago

@JustinMoss Thanks for the hard work! Been meaning to do this forever...

@loic-sharma Thank you so much for the pointers! I certainly will switch this over to use service indexes but will take this PR for now as it gets the hard work done.