I don't want to rely on nuget service for downloading dependency. I want to download and use nuget packages locally in my .Net Core app. Is it possible?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
Approach is the same as was before: open your NuGet.config file and add your local feed (path to local folder with pacakages. See Hosting your own Nuget feed doc):
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<add key="AspNetVNext" value="https://www.myget.org/F/aspnetcidev/api/v3/index.json" />
...
<add key="LocalFeed" value="<path to your local folder>" />
</packageSources>
You can modify default NuGet.config file
The default location for NuGet's configuration file is %APPDATA%\NuGet\NuGet.Config (DOS) or $ENV:APPDATA\NuGet\NuGet.Config (PowerShell).
or create your own file in root folder of your solution.