<Project Sdk="Microsoft.NET.Sdk">
    <PropertyGroup>
        <TargetFramework>net8.0</TargetFramework>
        <ImplicitUsings>enable</ImplicitUsings>
        <Nullable>enable</Nullable>
        <AssemblySearchPaths>$(AssemblySearchPaths);$(GDWeavePath)/core</AssemblySearchPaths>
    </PropertyGroup>

    <ItemGroup>
        <Reference Include="GDWeave" Private="false"/>
        <Reference Include="Serilog" Private="false"/>
    </ItemGroup>

    <ItemGroup>
        <None Include="manifest.json" CopyToOutputDirectory="PreserveNewest"/>
    </ItemGroup>

    <Target
        Name="PostBuild"
        AfterTargets="PostBuildEvent"
        Condition="'$(GDWeavePath)' != ''">
        <Exec
            Command="xcopy /Y /I &quot;$(TargetDir)&quot; &quot;$(GDWeavePath)/mods/$(AssemblyName)&quot;"
            Condition="'$([System.Runtime.InteropServices.RuntimeInformation]::IsOSPlatform($([System.Runtime.InteropServices.OSPlatform]::Windows)))'"
        />
    </Target>
</Project>
