C
C#8mo ago
Brady Kelly

✅ Add NuGet packages to Git

I'm frequently offline and this is driving me nuts. Last night I did a git reset in a temper tantrum and NuGet threw its toys. Now I thought I could just go and add <project>/packages to my repo, but that folder doesn't exist. I can only find C:\Program Files (x86)\Microsoft SDKs\NuGetPackages and C:\Program Files (x86)\Microsoft Visual Studio\Shared\NuGetPackages. The latter doesn't look promising but I could maybe, at a push (it makes me queasy), add the SDK one. Yet I'd rather not make a bad situation worse by including all projects' packages to git for one project. Surely there is a way I can configure NuGet to use a packages folder again? When I set the local packages folder to packages and do a restore, then click the link for packages folder I get taken the global packages folder, C:\Users\brady\.nuget\packages, and the confgured local folder <project>/packages still doesn't exist. Either Rider or I have a case of mistaken identity here, but to me, local bloody means local.
1 Reply
Brady Kelly
Brady KellyOP8mo ago
I'll look at that, thanks, rather than go back to packages.config. I was kind of hoping I could let Git look after my packages locally, without pushing, but that won't happen this year. Restoring from git remote or from nuget both need a connection anyway, so I might as well give up on this one.
Want results from more Discord servers?
Add your server