-
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathDirectory.Build.props
27 lines (22 loc) · 1.37 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
<Project>
<PropertyGroup>
<GenerateDocumentationFile>false</GenerateDocumentationFile>
<LangVersion>latest</LangVersion>
<ImplicitUsings>true</ImplicitUsings>
<Nullable>annotations</Nullable>
<PackOnBuild>true</PackOnBuild>
<!-- Avoid deleting older packed versions to avoid rebuild errors (since package is in same solution, which is uncommon) -->
<EnablePackCleanup>false</EnablePackCleanup>
<PackageOutputPath>$([System.IO.Path]::GetFullPath('$(MSBuildThisFileDirectory)bin'))</PackageOutputPath>
<RestoreSources>https://pkg.kzu.app/index.json;https://api.nuget.org/v3/index.json</RestoreSources>
<RestoreSources Condition="Exists('$(PackageOutputPath)')">$(PackageOutputPath);$(RestoreSources)</RestoreSources>
<!-- Roslyn caches analyzers aggressively so we are better off using a very dynamic version number
for local builds where a quick devloop is key. We bump version every 10 seconds -->
<Epoc>$([System.DateTime]::Parse("2024-03-15"))</Epoc>
<TotalDays>$([System.DateTime]::UtcNow.Subtract($(Epoc)).TotalDays)</TotalDays>
<Days>$([System.Math]::Truncate($(TotalDays)))</Days>
<Seconds>$([System.Math]::Floor($([MSBuild]::Divide($([System.DateTime]::UtcNow.TimeOfDay.TotalSeconds), 10))))</Seconds>
<Version>42.$(Days).$(Seconds)</Version>
<Product>SponsorableLib</Product>
</PropertyGroup>
</Project>