Here is info about our technical development environment :
-Microsoft Visual Studio Enterprise 2019
-.Net Core 3.1
-DevExpress v21.2.6 platform
- PostgreSQL 14.2, compiled by Visual C++ build 1914, 64-bit
Microsoft.AspNet.Providers.Core 2.0.0
Microsoft.EntityFrameworkCore 5.0.15
Microsoft.EntityFrameworkCore.Design 5.0.15
Microsoft.EntityFrameworkCore.Tools 5.0.15
Microsoft.OpenApi 1.2.3
Npgsql 5.0.12
Npgsql.EntityFrameworkCore.PostgreSQL 5.0.10
Swashbuckle.AspNetCore 6.3.0
Since I’m using .Net Core 3.1 , I ensured the following setting:
- In Visual Studio 2019, Tools - Nuget Package Manager - Package Manager SettingsDefault package management format: Packages.Reference
Within my solution’s directory’s NuGet.config file, I have the following xml markup code:
<?xml version="1.0" encoding="utf-8"?><configuration><config><add key="globalPackagesFolder" value=".\packages" /></config><packageSources><add key="Nexus" value=http://blahblah.com/nuget-group/ /></packageSources></configuration>
Therefore, the packages directory is at the root of the solution’s directory.
I do Not want the packages directory to be committed to the Git code repository, therefore, if anyone does a fresh brand new pull for the first time said solution code then they will Not have the packages directory.
Therefore, if someone opens up said solution for the very first time in Visual Studio 2019, they will get the following types of errors:
Severity CodeError NETSDK1064DescriptionPackage Microsoft.AspNetCore.Http.Abstractions, version 2.2.0 was not found. It might have been deleted since NuGet restore. Otherwise, NuGet restore might have only partially completed, which might have been due to maximum path length restrictions.Severity CodeError NETSDK1064DescriptionPackage Microsoft.CodeAnalysis.Analyzers, version 2.9.4 was not found. It might have been deleted since NuGet restore. Otherwise, NuGet restore might have only partially completed, which might have been due to maximum path length restrictions.
Could someone please tell me how I can go about modifying said configuration in such away that it would create the packages directory if they do Not exists ( preferably some kind of switch setting within the NuGet.config file ) ?