From 6ba6991e885263be9a6489898cb90bbdd9109c9a Mon Sep 17 00:00:00 2001 From: Nikolche Kolev Date: Fri, 28 Feb 2020 12:23:51 -0800 Subject: [PATCH 1/2] Clarify NU1105 --- docs/reference/errors-and-warnings/NU1105.md | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/docs/reference/errors-and-warnings/NU1105.md b/docs/reference/errors-and-warnings/NU1105.md index b0e32fa5e..a7728efe2 100644 --- a/docs/reference/errors-and-warnings/NU1105.md +++ b/docs/reference/errors-and-warnings/NU1105.md @@ -18,4 +18,17 @@ f1_keywords: The project file exists but no restore information was provided for it. ### Solution -In Visual Studio, the error could mean that the project is unloaded, in which case reload the project. From the command line this could mean that the file is corrupt or that it doesn't contain the custom "after imports" target needed for restore to read the project. Check that the project file is valid and contains an "after imports" target. \ No newline at end of file + +#### Command line + +From the command line this could mean that the file is corrupt or that the `NuGet.targets` are not imported. +To import the `NuGet.targets`, usually it's recommended to import the `Microsoft.Common.targets`. + +#### Visual Studio + +In Visual Studio the error could mean that targets are not import similar to the command line scenario. + +The error could also mean that the project is unloaded. + +* If you are using Visual Studio 2019 or later, NuGet has the ability to re-use artifacts from the previous restore for unloaded projects. In order for this scenario to work, you need to ensure that all projects currently in the solution have been restored from the command line prior to loading them in Visual Studio. +* Alternatively, just reload the project. From 38c408976af215b9cc29392827973249af3c8b7a Mon Sep 17 00:00:00 2001 From: Karan Nandwani Date: Fri, 28 Feb 2020 15:08:44 -0800 Subject: [PATCH 2/2] Update docs/reference/errors-and-warnings/NU1105.md Co-Authored-By: Andy Zivkovic --- docs/reference/errors-and-warnings/NU1105.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/reference/errors-and-warnings/NU1105.md b/docs/reference/errors-and-warnings/NU1105.md index a7728efe2..f6c4f9f93 100644 --- a/docs/reference/errors-and-warnings/NU1105.md +++ b/docs/reference/errors-and-warnings/NU1105.md @@ -31,4 +31,4 @@ In Visual Studio the error could mean that targets are not import similar to the The error could also mean that the project is unloaded. * If you are using Visual Studio 2019 or later, NuGet has the ability to re-use artifacts from the previous restore for unloaded projects. In order for this scenario to work, you need to ensure that all projects currently in the solution have been restored from the command line prior to loading them in Visual Studio. -* Alternatively, just reload the project. +* Alternatively, reload the project.