Automatically copy or mirror NuGet when installing a package (push to private repo)

Probelm

I want to set up a no commit workflow for NuGet. But for this I need to make sure that I have copies of any third-party packages, as well as the dependencies installed from nuget.org, copied to our private repo.

NuGet Mirror

I looked at the NuGet mirror command, but it looks like a manual process. https://docs.nuget.org/docs/reference/command-line-reference#Mirror_Command

Copy of NuGet

I also looked at a copy of NuGet, but could A) not make it work, and B) it still looks like a manual process. https://www.nuget.org/packages/nuget.copy.extension/1.2.0

Are there any solutions for this automatically when installing the package? I cannot get developers to remember to manually copy packages after they are installed. When a developer installs a package, I want it to be copied to our private NuGet repository. Please guide me in the right direction.

+4
source share
1 answer

I am not aware of any built-in NuGet function for this, but here is an easy way to make sure that all packets are in sync with shared storage.

NuGet saves all downloaded packages to C: \ Users \ username \ AppData \ Local \ NuGet \ Cache

, BitTorrent Sync, . BTSync , .

+3

Source: https://habr.com/ru/post/1538076/


All Articles