Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/EFCore.Tools/tools/EntityFrameworkCore.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -1298,6 +1298,12 @@ function EF($project, $startupProject, $params, $applicationArgs, [switch] $skip
'Core Package Manager Console Tools don''t support this platform. See https://aka.ms/efcore-docs-pmc-tfms for more ' +
'information.'
}
if ($targetPlatformIdentifier)
{
Write-Warning "Startup project '$($startupProject.ProjectName)' targets platform '$targetPlatformIdentifier'. The Entity " +
'Framework Core Package Manager Console Tools don''t support this platform. See https://aka.ms/efcore-docs-pmc-tfms ' +
'for more information.'
}

$exePath = (Get-Command 'dotnet').Path

Expand Down
6 changes: 6 additions & 0 deletions src/dotnet-ef/RootCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,12 @@ protected override int Execute(string[] _)
startupProject.AssemblyName + ".runtimeconfig.json");
var projectAssetsFile = startupProject.ProjectAssetsFile;

if (!string.IsNullOrEmpty(startupProject.TargetPlatformIdentifier))
Comment thread
AndriySvyryd marked this conversation as resolved.
Outdated
{
Reporter.WriteWarning(
Resources.UnsupportedPlatform(startupProject.ProjectName, startupProject.TargetPlatformIdentifier));
}

var targetFramework = new FrameworkName(startupProject.TargetFrameworkMoniker!);
if (targetFramework.Identifier == ".NETFramework")
{
Expand Down