-
Notifications
You must be signed in to change notification settings - Fork 1
/
Directory.Build.props
59 lines (50 loc) · 3.07 KB
/
Directory.Build.props
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
<Project>
<PropertyGroup Label="Frameworks">
<ClassLibTargetFrameworks>netstandard2.0;net7.0;net8.0;net9.0</ClassLibTargetFrameworks>
<TestTargetFrameworks>net6.0;net7.0;net8.0;net9.0</TestTargetFrameworks>
<SampleTargetFramework>net9.0</SampleTargetFramework>
<!-- Unit tests are running against EOL SDKs as well. Disable all warnings related to EOL SDK -->
<CheckEolTargetFramework>false</CheckEolTargetFramework>
<SuppressTfmSupportBuildWarnings>true</SuppressTfmSupportBuildWarnings>
<!-- Suppress warnings related to preview SDKs -->
<SuppressNETCoreSdkPreviewMessage>true</SuppressNETCoreSdkPreviewMessage>
<LangVersion>latest</LangVersion>
</PropertyGroup>
<PropertyGroup Label="Versions">
<!-- Default version if not specified in dotnet command -->
<PackageVersion Condition="'$(PackageVersion)' == ''">0.1.0</PackageVersion>
<!-- Parse out parts of the version -->
<MajorVersion Condition="'$(MajorVersion)' == ''">$(PackageVersion.Split('.')[0])</MajorVersion>
<MinorVersion Condition="'$(MinorVersion)' == ''">$(PackageVersion.Split('.')[1])</MinorVersion>
<Patch Condition="'$(Patch)' == ''">$(PackageVersion.Split('-')[0].Split('.')[2])</Patch>
<BuildNumber Condition="'$(BuildNumber)' == ''">0</BuildNumber>
<VersionPrefix Condition="'$(VersionPrefix)' == ''">$(MajorVersion).$(MinorVersion).$(Patch)</VersionPrefix>
<VersionSuffix Condition="'$(VersionSuffix)' == '' AND $(PackageVersion.Contains('-'))">$(PackageVersion.Split('-')[1])</VersionSuffix>
<AssemblyVersion Condition="'$(AssemblyVersion)' == ''">$(VersionPrefix).$(BuildNumber)</AssemblyVersion>
<FileVersion Condition="'$(FileVersion)' == ''">$(VersionPrefix).$(BuildNumber)</FileVersion>
</PropertyGroup>
<!-- Common NuGet properties -->
<!-- Reference: https://docs.microsoft.com/en-us/nuget/reference/msbuild-targets#pack-target -->
<PropertyGroup>
<Authors>Zoltan Csizmadia</Authors>
<Owners>Zoltan Csizmadia</Owners>
<Description>Add DataContract and DataMember support to System.Text.Json.</Description>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageRequireLicenseAcceptance>false</PackageRequireLicenseAcceptance>
<PackageTags>Json, Serialization, System.Text.Json, DataContract</PackageTags>
<RepositoryUrl>https://github.com/zcsizmadia/ZCS.DataContractResolver</RepositoryUrl>
<PackageProjectUrl>https://github.com/zcsizmadia/ZCS.DataContractResolver</PackageProjectUrl>
<!-- <Copyright></Copyright> -->
<!-- <PackageIconUrl></PackageIconUrl> -->
</PropertyGroup>
<PropertyGroup>
<!-- By default none of the projects are packable by "dotnet pack". Packable projects must set it to true! -->
<IsPackable>false</IsPackable>
<WarnOnPackingNonPackableProject>false</WarnOnPackingNonPackableProject>
</PropertyGroup>
<ItemGroup>
<None Include="$(MSBuildThisFileDirectory)\LICENSE" Pack="true" PackagePath=""/>
<None Include="$(MSBuildThisFileDirectory)\README.md" Pack="true" PackagePath=""/>
</ItemGroup>
</Project>