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

  <!-- ProjectGuid is only included as a requirement for SonarQube analysis -->
  <PropertyGroup>
    <ProjectGuid>{E383961B-9356-4D5D-8233-9A1079D03055}</ProjectGuid>
  </PropertyGroup>

  <ItemGroup>
    <ProjectReference Include="..\Emby.Naming\Emby.Naming.csproj" />
    <ProjectReference Include="..\Emby.Notifications\Emby.Notifications.csproj" />
    <ProjectReference Include="..\Jellyfin.Api\Jellyfin.Api.csproj" />
    <ProjectReference Include="..\MediaBrowser.Model\MediaBrowser.Model.csproj" />
    <ProjectReference Include="..\MediaBrowser.Common\MediaBrowser.Common.csproj" />
    <ProjectReference Include="..\MediaBrowser.Controller\MediaBrowser.Controller.csproj" />
    <ProjectReference Include="..\MediaBrowser.Providers\MediaBrowser.Providers.csproj" />
    <ProjectReference Include="..\MediaBrowser.XbmcMetadata\MediaBrowser.XbmcMetadata.csproj" />
    <ProjectReference Include="..\Emby.Dlna\Emby.Dlna.csproj" />
    <ProjectReference Include="..\MediaBrowser.LocalMetadata\MediaBrowser.LocalMetadata.csproj" />
    <ProjectReference Include="..\Emby.Photos\Emby.Photos.csproj" />
    <ProjectReference Include="..\Emby.Drawing\Emby.Drawing.csproj" />
    <ProjectReference Include="..\MediaBrowser.MediaEncoding\MediaBrowser.MediaEncoding.csproj" />
  </ItemGroup>

  <ItemGroup>
    <PackageReference Include="Jellyfin.XmlTv" Version="10.6.2" />
    <PackageReference Include="Microsoft.AspNetCore.Hosting" Version="2.2.7" />
    <PackageReference Include="Microsoft.AspNetCore.Hosting.Abstractions" Version="2.2.0" />
    <PackageReference Include="Microsoft.AspNetCore.Hosting.Server.Abstractions" Version="2.2.0" />
    <PackageReference Include="Microsoft.AspNetCore.Http" Version="2.2.2" />
    <PackageReference Include="Microsoft.AspNetCore.Http.Extensions" Version="2.2.0" />
    <PackageReference Include="Microsoft.AspNetCore.ResponseCompression" Version="2.2.0" />
    <PackageReference Include="Microsoft.AspNetCore.Server.Kestrel" Version="2.2.0" />
    <PackageReference Include="Microsoft.AspNetCore.WebSockets" Version="2.2.1" />
    <PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="5.0.0" />
    <PackageReference Include="Microsoft.Extensions.Caching.Memory" Version="5.0.0" />
    <PackageReference Include="Microsoft.Extensions.Configuration.Abstractions" Version="5.0.0" />
    <PackageReference Include="Microsoft.Extensions.Hosting.Abstractions" Version="5.0.0" />
    <PackageReference Include="Mono.Nat" Version="3.0.1" />
    <PackageReference Include="prometheus-net.DotNetRuntime" Version="3.4.1" />
    <PackageReference Include="ServiceStack.Text.Core" Version="5.10.2" />
    <PackageReference Include="sharpcompress" Version="0.26.0" />
    <PackageReference Include="SQLitePCL.pretty.netstandard" Version="2.1.0" />
    <PackageReference Include="DotNet.Glob" Version="3.1.0" />
  </ItemGroup>

  <ItemGroup>
    <Compile Include="..\SharedVersion.cs" />
  </ItemGroup>

  <PropertyGroup>
    <TargetFramework>net5.0</TargetFramework>
    <GenerateAssemblyInfo>false</GenerateAssemblyInfo>
    <GenerateDocumentationFile>true</GenerateDocumentationFile>
    <TreatWarningsAsErrors Condition=" '$(Configuration)' == 'Release'">true</TreatWarningsAsErrors>
    <!-- https://github.com/microsoft/ApplicationInsights-dotnet/issues/2047 -->
    <NoWarn>AD0001</NoWarn>
  </PropertyGroup>

  <!-- Code Analyzers-->
  <ItemGroup Condition=" '$(Configuration)' == 'Debug' ">
    <PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.9.8" PrivateAssets="All" />
    <PackageReference Include="SerilogAnalyzer" Version="0.15.0" PrivateAssets="All" />
    <PackageReference Include="StyleCop.Analyzers" Version="1.1.118" PrivateAssets="All" />
    <PackageReference Include="SmartAnalyzers.MultithreadingAnalyzer" Version="1.1.31" PrivateAssets="All" />
  </ItemGroup>

  <PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">
    <CodeAnalysisRuleSet>../jellyfin.ruleset</CodeAnalysisRuleSet>
  </PropertyGroup>

  <ItemGroup>
    <EmbeddedResource Include="Localization\iso6392.txt" />
    <EmbeddedResource Include="Localization\countries.json" />
    <EmbeddedResource Include="Localization\Core\*.json" />
    <EmbeddedResource Include="Localization\Ratings\*.csv" />
  </ItemGroup>

</Project>