Nuget internet requirement - nuget

Having (presumably) understood the motivation behind Nuget, I want to know, whether we still require internet access to download a package which is already being downloaded earlier for different project in different solution?

I believe you can even set up your own feed stored on the file system as described here.

You can setup your own local NuGet repository as As Denis Ivin has already said.
NuGet also has its own local machine cache which keeps NuGet packages that you have installed previously (C:\Users[UserName]\AppData\Local\NuGet\Cache). You can install these by selecting the Recent packages tab in the Manage Packages dialog.
Having your own local NuGet repository is probably better since the cache could be cleared.

Related

Upgrading to LibMan from NuGet

We have a web app project that still uses NuGet for content packages management (jQuery, Knockback, knockoutjs, etc.). We are trying to convert to use LibMan, and running into an issue where some older packages do not exist (for instance walltime-js). How do we work around this issue?
Try using a different provider. The current default, Cdnjs, is a curated catalog; the other two providers, JSDelivr and Unpkg, host any package that's available in NPM and thus have much broader catalogs.

How are NuGet components intended to be distributed to end users?

I'm still learning about NuGet and have a (hopefully not stupid) question: how are the components/assemblies in NuGet packages intended to be distributed to end users? The docs I've found are all about how NuGet packages get installed on developer systems, but nothing addresses how the resulting software is shipped/installed.
My best guess is that the developer using the package must decide how to get the components or assemblies to the end users, presumably by including them inside whatever installer the developer builds. The developer is also presumably responsible for any required registration (if side-by-side installation is not sufficient). Basically I'm guessing that NuGet and the concept of packages are out of the loop at this stage. Is that right?
They aren't intended for end users. NuGets purpose is to help developers manage their software dependencies. The developers still package and deploy their application and its dependencies the same way they always have.
This can be via an MSI installer, exe installer, ClickOnce or Windows Store installation.
NuGet adds the assemblies as references to your application's project. When you compile your application, you'll see all the assemblies you pulled in via NuGet in the output directory (typically bin\debug or bin\release).
The idea here, as Andy says, is that these assemblies are now part of your application just as if you had found the assembly and referenced it manually.
Basically I'm guessing that NuGet and the concept of packages are out of the loop at this stage. Is that right?
Yep. However you plan to ship your application binary is the same way you distribute the assemblies that were "installed" by the NuGet packages. You don't need to distribute the packages, just the assemblies that were referenced by your application.

NuGet private feed not updating DownloadCount

I have set up a small test Nuget private repository on my machine following this guide.
Everything is working perfectly and I can publish packages, update versions, download them etc. The only problem is that the DownloadCount of my packages is always 0 regardless of how many times I download it.
I downloaded NuGet source but could not find a place where this value is updated. Moreover, nuget does not seem to use any DB technology so probably the feed is just generated on demand from the contents of the Packages folder.
Does anyone have any idea if this is a known issue or if it's a problem in my setup or if I should just add some code to the server to record downloads myself?
Thanks!
NuGet.Server based web sites are simply a front-end exposing an OData feed on top of a file share. There's no real database behind it, no indexing, no auditing, tracing, metrics or statistics, or any of that kind of stuff.
You could build it yourself, or take a look at alternatives such as MyGet, ProGet, Artifactory, etc.

How to host a package on NuGet.org?

I have an open source project SystemWrapper. Someone recently asked me to add it to NuGet gallery. I had no problem to create a NuGet package. However, I cannot figure out how to add my package to NuGet Gallery.
Can someone point me to a link that describes how I can do that or tell me the steps I need to make.
I think the page at http://docs.nuget.org/docs/creating-packages/creating-and-publishing-a-package may be what you're looking for.
The basic process appears to be to register for an account at NuGet.org, tell your local NuGet package manager your API key, then "push" your component.
Good luck!

How to host NuGet packages locally?

I am writing framework components for a project I am working on and I'm wondering if it's possible to host a NuGet package locally without a server so I'll be able to create a full release cycle just by using my computer.
If it's possible, please explain how to do it.
You can use a regular folder. More info here:
http://docs.nuget.org/docs/creating-packages/hosting-your-own-nuget-feeds