Skip to content

Commit

Permalink
Переводит проект на CPM и удаляет явную поддержку net6 и net7.
Browse files Browse the repository at this point in the history
Она продолжает поддерживаться через netstandard2.0
  • Loading branch information
inyutin-maxim committed Nov 19, 2024
1 parent 959d2bc commit 9d7f568
Show file tree
Hide file tree
Showing 6 changed files with 92 additions and 64 deletions.
8 changes: 8 additions & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<Project>
<PropertyGroup>
<NoWarn>CS8632;RS0016</NoWarn>
<EnforceCodeStyleInBuild>true</EnforceCodeStyleInBuild>
<DefineConstants>JETBRAINS_ANNOTATIONS</DefineConstants>
<LangVersion>latest</LangVersion>
</PropertyGroup>
</Project>
41 changes: 0 additions & 41 deletions Directory.Build.targets

This file was deleted.

50 changes: 50 additions & 0 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
<Project>
<PropertyGroup>
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
<CentralPackageTransitivePinningEnabled>true</CentralPackageTransitivePinningEnabled>
</PropertyGroup>
<ItemGroup>
<PackageVersion Include="AsyncFixer" Version="1.6.0" PrivateAssets="all" />
<PackageVersion Include="HtmlAgilityPack" Version="1.11.71" />
<PackageVersion Include="Newtonsoft.Json" Version="13.0.3" />
<PackageVersion Include="SonarAnalyzer.CSharp" Version="9.32.0.97167" PrivateAssets="all" />
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="9.0.0" />
<PackageVersion Include="System.Text.Encoding.CodePages" Version="9.0.0" />
<PackageVersion Include="Microsoft.SourceLink.GitHub" Version="8.0.0" />
<PackageVersion Include="FluentAssertions" Version="6.12.2" />
<PackageVersion Include="FluentAssertions.Analyzers" Version="0.34.1">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageVersion>
<PackageVersion Include="Meziantou.FluentAssertionsAnalyzers" Version="1.0.21">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageVersion>
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.12.0" />
<PackageVersion Include="Moq.AutoMock" Version="3.5.0" />
<PackageVersion Include="xunit" Version="2.9.2" />
<PackageVersion Include="xunit.runner.visualstudio" Version="2.8.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageVersion>
<PackageVersion Include="coverlet.collector" Version="6.0.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageVersion>
<PackageVersion Include="coverlet.msbuild" Version="6.0.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageVersion>
</ItemGroup>
<ItemGroup Label="Включено в каждый проект">
<PackageReference Include="JetBrains.Annotations" />
<PackageVersion Include="JetBrains.Annotations" Version="2024.3.0" />
<PackageReference Include="TestableIO.System.IO.Abstractions.Analyzers">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageVersion Include="TestableIO.System.IO.Abstractions.Analyzers" Version="2022.0.0" />
<ProjectReference Include="../Reo.Core.Analyzers/Reo.Core.Analyzers.csproj" OutputItemType="Analyzer" ReferenceOutputAssembly="false" Condition="$(RootNamespace) != 'Reo.Core.Analyzers.Tests' AND $(RootNamespace) != 'Reo.Core.Analyzers' AND $(RootNamespace) != 'Reo.Core.CodeGenerator'" />
</ItemGroup>
</Project>
26 changes: 13 additions & 13 deletions VkNet.Tests/VkNet.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,42 +1,42 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<IsPackable>false</IsPackable>
<TargetFramework>net7.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<LangVersion>latest</LangVersion>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="FluentAssertions" Version="6.11.0" />
<PackageReference Include="FluentAssertions.Analyzers" Version="0.21.0">
<PackageReference Include="FluentAssertions"/>
<PackageReference Include="FluentAssertions.Analyzers">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Meziantou.FluentAssertionsAnalyzers" Version="1.0.10">
<PackageReference Include="Meziantou.FluentAssertionsAnalyzers">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.6.3" />
<PackageReference Include="Moq.AutoMock" Version="3.5.0" />
<PackageReference Include="xunit" Version="2.5.0" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.0">
<PackageReference Include="Microsoft.NET.Test.Sdk"/>
<PackageReference Include="Moq.AutoMock"/>
<PackageReference Include="xunit"/>
<PackageReference Include="xunit.runner.visualstudio">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="coverlet.collector" Version="6.0.0">
<PackageReference Include="coverlet.collector">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="coverlet.msbuild" Version="6.0.0">
<PackageReference Include="coverlet.msbuild">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\VkNet\VkNet.csproj" />
<ProjectReference Include="..\VkNet\VkNet.csproj"/>
</ItemGroup>
<ItemGroup>
<Service Include="{82a7f48d-3b50-4b1e-b82e-3ada8210c358}" />
<Service Include="{82a7f48d-3b50-4b1e-b82e-3ada8210c358}"/>
</ItemGroup>
<ItemGroup>
<None Update="TestData\**\*.*" CopyToOutputDirectory="Always" />
<None Update="TestData\**\*.*" CopyToOutputDirectory="Always"/>
</ItemGroup>
</Project>
4 changes: 4 additions & 0 deletions VkNet.sln
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{C768206C-73C8-46F7-BD48-0119C60EAC63}"
ProjectSection(SolutionItems) = preProject
.editorconfig = .editorconfig
Directory.Build.props = Directory.Build.props
Directory.Packages.props = Directory.Packages.props
LICENCE = LICENCE
README.md = README.md
EndProjectSection
EndProject
Global
Expand Down
27 changes: 17 additions & 10 deletions VkNet/VkNet.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net7.0;net8.0;net6.0;netstandard2.0</TargetFrameworks>
<TargetFrameworks>net8.0;netstandard2.0</TargetFrameworks>
<AssemblyName>VkNet</AssemblyName>
<VersionPrefix>1.79.0-alpha</VersionPrefix>
<VersionSufix>
Expand Down Expand Up @@ -59,23 +59,30 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="AsyncFixer" Version="1.6.0" PrivateAssets="all"/>
<PackageReference Include="HtmlAgilityPack" Version="1.11.50"/>
<PackageReference Include="Newtonsoft.Json" Version="13.0.3"/>
<PackageReference Include="SonarAnalyzer.CSharp" Version="9.5.0.73987" PrivateAssets="all"/>
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="7.0.0"/>
<PackageReference Include="Microsoft.Extensions.Logging.Abstractions" Version="7.0.1"/>
<PackageReference Include="System.Text.Encoding.CodePages" Version="7.0.0"/>
<PackageReference Update="Reo.Core.Analyzers" Version="6.0.31201">
<PackageReference Include="AsyncFixer" PrivateAssets="all"/>
<PackageReference Include="HtmlAgilityPack" />
<PackageReference Include="Newtonsoft.Json" />
<PackageReference Include="SonarAnalyzer.CSharp" PrivateAssets="all"/>
<PackageReference Include="Microsoft.Extensions.DependencyInjection" />
<PackageReference Include="Microsoft.Extensions.Logging.Abstractions" />
<PackageReference Include="System.Text.Encoding.CodePages" />
<PackageReference Update="Reo.Core.Analyzers" >
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="8.0.0" PrivateAssets="All" />
<PackageReference Include="Microsoft.SourceLink.GitHub" />
</ItemGroup>

<ItemGroup>
<None Include="..\tools\vknet-icon.PNG" Pack="true" PackagePath="\"/>
<None Include="..\LICENCE" Pack="true" PackagePath="\"/>
<None Include="..\README.md" Pack="true" PackagePath="\"/>
</ItemGroup>

<ItemGroup>
<PackageVersion Update="Microsoft.SourceLink.GitHub" Version="8.0.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageVersion>
</ItemGroup>
</Project>

0 comments on commit 9d7f568

Please sign in to comment.