Skip to content

Commit

Permalink
Web API tutorial - Add EF tools package (#31344)
Browse files Browse the repository at this point in the history
* Web API tutorial - Add EF tools package

* Updated 7.0 VSC to use v7.0 for InMemory package and .NET 7.0 for project creation

* For v7 topic added v7 EF Tool package in scaffolding section

* Update aspnetcore/tutorials/first-web-api/includes/first-web-api3-7.md

Co-authored-by: Tom Dykstra <[email protected]>

---------

Co-authored-by: Tom Dykstra <[email protected]>
  • Loading branch information
wadepickett and tdykstra authored Jan 4, 2024
1 parent 43482df commit 38c523b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
3 changes: 2 additions & 1 deletion aspnetcore/tutorials/first-web-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ author: wadepickett
description: Learn how to build a web API with ASP.NET Core.
ms.author: wpickett
ms.custom: mvc, engagement-fy24
ms.date: 12/04/2023
ms.date: 01/03/2024
uid: tutorials/first-web-api
---

Expand Down Expand Up @@ -310,6 +310,7 @@ Run the following commands:
dotnet add package Microsoft.VisualStudio.Web.CodeGeneration.Design
dotnet add package Microsoft.EntityFrameworkCore.Design
dotnet add package Microsoft.EntityFrameworkCore.SqlServer
dotnet add package Microsoft.EntityFrameworkCore.Tools
dotnet tool uninstall -g dotnet-aspnet-codegenerator
dotnet tool install -g dotnet-aspnet-codegenerator
dotnet tool update -g dotnet-aspnet-codegenerator
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,15 +54,15 @@ The following diagram shows the design of the app.
* Run the following commands:

```dotnetcli
dotnet new webapi -o TodoApi
dotnet new webapi -o TodoApi -f net7.0
cd TodoApi
dotnet add package Microsoft.EntityFrameworkCore.InMemory
dotnet add package Microsoft.EntityFrameworkCore.InMemory -v 7.0.0
code -r ../TodoApi
```

These commands:

* Create a new web API project and open it in Visual Studio Code.
* Create a new web API project that targets .NET 7.0 and open it in Visual Studio Code.
* Add a NuGet package that is needed for the next section.
* Open the *TodoApi* folder in the current instance of Visual Studio Code.

Expand Down Expand Up @@ -293,6 +293,7 @@ Run the following commands:
dotnet add package Microsoft.VisualStudio.Web.CodeGeneration.Design -v 7.0.0
dotnet add package Microsoft.EntityFrameworkCore.Design -v 7.0.0
dotnet add package Microsoft.EntityFrameworkCore.SqlServer -v 7.0.0
dotnet add package Microsoft.EntityFrameworkCore.Tools -v 7.0.0
dotnet tool uninstall -g dotnet-aspnet-codegenerator
dotnet tool install -g dotnet-aspnet-codegenerator
dotnet tool update -g dotnet-aspnet-codegenerator
Expand Down

0 comments on commit 38c523b

Please sign in to comment.