9

I use Asp.net core mvc for web developing. I want to enable entityframework migrations via Entity Framework Core .NET Command Line Tools:

dotnet ef migrations add InitialDatabase

but an error occurs: unable to generate deps.json, it may have been already generated: C:\Program Files\dotnet\sdk\2.0.2\Sdks\Microsoft.NET.Sdk\build\GenerateDeps\GenerateDeps.proj

Are there any .NET Core configs that I missed?

1
  • 1
    Try running dotnet restore first. Commented Nov 19, 2017 at 14:03

3 Answers 3

0

When I add a service reference to a regular.net core web application, I got the similar error.

Error:Unable to generate deps.json, it may have been already generated. You can specify the "-d" option before the tool name for diagnostic output (for example, "dotnet -d ": C:\Program Files\dotnet\sdk\2.1.502\Sdks\Microsoft.NET.Sdk\targets\GenerateDeps\GenerateDeps.proj

After the investigation I came to know that, somehow svcutil was not installed. Once I installed svcutil using Nuget Package Manager (Install-Package dotnet-svcutil), this issue resolved.

0

you need to install :

The Windows Communication Foundation (WCF) dotnet-svcutil tool is a .NET Core CLI tool that retrieves metadata from a web service on a network location or from a WSDL file, and generates a WCF class containing client proxy methods that access the web service operations.

> Install-Package dotnet-svcutil -Version 1.0.4
0

My project was using dotnet core 2.2. I had to use dotnet-svcutil 1.0.4 because higher versions did not work for me. Installing dotnet-svcutil did the trick for me. You can search for dotnet-svcutil under "Manage Packages for solution" from Nuget Packages Manager under tools and then install

Not the answer you're looking for? Browse other questions tagged or ask your own question.