.NET Tips and Tricks

Blog archive

Creating a NuGet Web Site

In my regular Practical.NET column, I showed how easy it is to create NuGet packages and discussed how it was a much better way for a developer to share anything you've created, from Entity Framework classes to JavaScript files (my example was a package that implemented an HtmlHelper consisting of a DLL and a JavaScript file). NuGet also allows you to attach searchable documentation to your package to ensure that a developer can find your package, recognize it and know what your code does.

In that article, I showed how to use a folder as a repository for NuGet packages. But if you'd like something a little more professional, you can create a NuGet Web site. It's easy to do: First, in Visual Studio, create an Empty Web Application. Once the project appears in Solution Explorer, right-click on it and select Manage NuGet Packages. In the NuGet Package Manager, do a search for the NuGet.Server package and install it.

After deploying your Website, you just need to do two things:

  1. Save your NuGet packages into the Packages folder in your new site.
  2. Tell Visual Studio about your site.

My earlier article walks through both processes. You can get the information for your site by surfing to it with your browser -- its default page provides both the file path to the folder you should save your package in and the URL you should use when telling Visual Studio about your NuGet site.

I'll put in one caveat: I only tested this on IIS 7.

Posted by Peter Vogel on 12/03/2015


comments powered by Disqus

Featured

  • Data Science Pack for VS Code Bundles Python, Data and Copilot Tools

    New extension pack bundles wildly popular tools for Python development, assisted by the AI-powered GitHub Copilot and a data wrangler.

  • Lessons Learned Building a GenAI-Powered App

    Sometimes, complex technical achievements are best explained through one example. That's the approach Mete Atamel, Developer Advocate at Google, is taking as he makes the rounds detailing the capabilities of Vertex AI and associated tooling on the Google Cloud Platform.

  • 30th Annual Visual Studio Magazine Reader's Choice Awards Announced

    For the 30th year in a row, Visual Studio Magazine readers have chosen the best tools and services for developers. The 2024 winners are honored in 43 categories, from component suites to testing tools to AI helpers.

  • Another Report Weighs In on GitHub Copilot Dev Productivity: 👎

    Several reports have answered "yes" to the question of whether GitHub Copilot improves developer productivity. A new one says "no."

Subscribe on YouTube