Skip to content
Snippets Groups Projects
Commit b945e996 authored by Benedikt Heinrichs's avatar Benedikt Heinrichs
Browse files

Update nuget.md

parent 6965a73d
No related branches found
No related tags found
No related merge requests found
Pipeline #154415 passed
......@@ -5,10 +5,19 @@ To include local NuGet packages, you need to download and install (and set the p
Get it from here: [nuget.org/downloads](https://www.nuget.org/downloads)
## Usage
For more detailed instructions see: [medium.com/@churi.vibhav/creating-and-using-a-local-nuget-package-repository](https://medium.com/@churi.vibhav/creating-and-using-a-local-nuget-package-repository-9f19475d6af8)
For more detailed instructions see: [Creating and using a local nuget package repository](https://medium.com/@churi.vibhav/creating-and-using-a-local-nuget-package-repository-9f19475d6af8)
The basic steps are:
1. Go to the location of your NuGet package and add it to your local NuGet repository:
1. Create the NuGet package using Visual Studio or cake build script:
1. For Visual Studio:
* Create a .NET standard class library.
* In project properties > package => fill assembly details.
* In the solution explorer, right click the project => click "Pack".
2. For cake:
* Add our .nuspec file template, if not present
* Run the command .\build.ps1 -Configuration Release -Target Release to build the project under release
* Run the command .\build.ps1 -Configuration Release -Target NugetPack to pack it
2. Add the package to the local NuGet repository:
```
>nuget add <package_id>.nupkg -source <source_path>\<nuget_repo_name>
```
......@@ -17,9 +26,9 @@ The basic steps are:
>tree
```
and you should see the added package in the repository tree.
2. To import the local package, open the project that you want to include the package in Visual Studio.
3. In the solution explorer, right click the solution => click "manage NuGet packages for solution..."
4. Click settings (little gear icon near "Manage Packages for Solution" in the top right corner).
5. Add the local package (click "+", set the source path to the local package).
6. Move the local package you just added above the nuget.org path to give it higher priority.
7. Now you should be able to find, install and use the local package like any other nuget package.
\ No newline at end of file
3. To import the local package, open the project that you want to include the package in Visual Studio.
4. In the solution explorer, right click the solution => click "manage NuGet packages for solution..."
5. Click settings (little gear icon near "Manage Packages for Solution" in the top right corner).
6. Add the local package (click "+", set the source path to the local package).
7. Move the local package you just added above the nuget.org path to give it higher priority.
8. Now you should be able to find, install and use the local package like any other nuget package.
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment