当尝试使用
dotnet ef migrations add Initial
命令为我的项目创建迁移时,我遇到了以下错误 dotnet : You must install or update .NET to run this application.
。
这个问题的解决方案是什么?将 Entity Framework 降级到版本 5.0.5 并重新安装 dotnet-ef 工具不起作用。
您可以使用
检查您的 .net 运行时dotnet --list-runtimes
确保您已安装 .net8 的运行时
您可以在此处下载运行时:https://dotnet.microsoft.com/en-us/download/dotnet/8.0