<Project Sdk="Microsoft.NET.Sdk">

  <PropertyGroup>
    <TargetFramework>net8.0</TargetFramework>
    <Version>5.1.0</Version>
    <Product>Oqtane</Product>
    <Authors>Shaun Walker</Authors>
    <Company>.NET Foundation</Company>
    <Description>Modular Application Framework for Blazor and MAUI</Description>
    <Copyright>.NET Foundation</Copyright>
    <PackageProjectUrl>https://www.oqtane.org</PackageProjectUrl>
    <PackageLicenseUrl>https://github.com/oqtane/oqtane.framework/blob/dev/LICENSE</PackageLicenseUrl>
    <PackageReleaseNotes>https://github.com/oqtane/oqtane.framework/releases/tag/v5.1.0</PackageReleaseNotes>
    <RepositoryUrl>https://github.com/oqtane/oqtane.framework</RepositoryUrl>
    <RepositoryType>Git</RepositoryType>
    <CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies>
  </PropertyGroup>

  <PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">
    <OutputPath>bin</OutputPath>
  </PropertyGroup>

  <PropertyGroup Condition=" '$(Configuration)' == 'Release' ">
    <OutputPath>bin</OutputPath>
  </PropertyGroup>

  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
    <NoWarn>1701;1702;EF1001;AD0001</NoWarn>
  </PropertyGroup>

  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
    <NoWarn>1701;1702;EF1001;AD0001</NoWarn>
  </PropertyGroup>

  <ItemGroup>
    <PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer" Version="8.0.2" />
  </ItemGroup>

  <ItemGroup>
    <ProjectReference Include="..\Oqtane.Server\Oqtane.Server.csproj" />
  </ItemGroup>

  <ItemGroup>
    <SqlServerFiles Include="$(OutputPath)Oqtane.Database.SqlServer.dll;$(OutputPath)Oqtane.Database.SqlServer.pdb;$(OutputPath)Microsoft.EntityFrameworkCore.SqlServer.dll" DestinationPath="..\Oqtane.Server\bin\$(Configuration)\net8.0\%(Filename)%(Extension)" />
  </ItemGroup>

  <Target Name="PublishProvider" AfterTargets="PostBuildEvent" Inputs="@(SqlServerFiles)" Outputs="@(SqlServerFiles->'%(DestinationPath)')">
    <Copy SourceFiles="@(SqlServerFiles)" DestinationFiles="@(SqlServerFiles->'%(DestinationPath)')" />
  </Target>

</Project>
