Skip to content

Commit 237c918

Browse files
authored
Merge pull request #3 from atc-net/hotfix/nuget_package2
Ensure Nerdbank is setup in src/directory.build.props
2 parents 41b923f + 2fd3756 commit 237c918

File tree

1 file changed

+38
-1
lines changed

1 file changed

+38
-1
lines changed

src/Directory.Build.props

Lines changed: 38 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,20 @@
66
-->
77
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory).., Directory.Build.props))\Directory.Build.props" />
88

9+
<!-- Global nuget package configurations that should not be needed to change -->
10+
<PropertyGroup Label="Global Nuget Package metadata">
11+
<RepositoryUrl>https://github.com/$(OrganizationName)/$(RepositoryName)</RepositoryUrl>
12+
<RepositoryType>git</RepositoryType>
13+
<PublishRepositoryUrl>true</PublishRepositoryUrl>
14+
<PackageLicenseExpression>MIT</PackageLicenseExpression>
15+
<PackageProjectUrl>https://github.com/$(OrganizationName)/$(RepositoryName)</PackageProjectUrl>
16+
<PackageIcon>icon.png</PackageIcon>
17+
</PropertyGroup>
18+
19+
<ItemGroup>
20+
<None Include="..\..\images\icon.png" Pack="true" PackagePath="\" Visible="false" />
21+
</ItemGroup>
22+
923
<PropertyGroup Label="Build instructions">
1024
<OutputType>Library</OutputType>
1125
<!-- Creates a regular package and a symbols package -->
@@ -19,5 +33,28 @@
1933
<EmbedUntrackedSources>true</EmbedUntrackedSources>
2034
<!-- Recommended: Embed symbols containing Source Link in the main file (exe/dll) -->
2135
<DebugType>embedded</DebugType>
36+
<!-- Will generate nuget packages for each project -->
37+
<GeneratePackageOnBuild>false</GeneratePackageOnBuild>
38+
<!-- Web projects aren't packable by default. To override the default behavior, add the following -->
39+
<IsPackable>true</IsPackable>
2240
</PropertyGroup>
23-
</Project>
41+
42+
<!--
43+
By default builds are non-deterministic, meaning there is no guarantee that building the same code twice(on the same or different machines)
44+
will produce exactly the same binary output. Deterministic builds are important as they enable verification that the resulting
45+
binary was built from the specified source and provides traceability.
46+
47+
To enable deterministic builds a property should be set to through: ContinuousIntegrationBuild.
48+
49+
Important: This property should not be enabled during local development as the debugger won't be able to find the local source files.
50+
-->
51+
<PropertyGroup Condition="'$(GITHUB_ACTIONS)' == 'true'">
52+
<ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
53+
</PropertyGroup>
54+
55+
<ItemGroup>
56+
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="8.0.0" PrivateAssets="All" />
57+
<PackageReference Include="Nerdbank.GitVersioning" Version="3.6.133" PrivateAssets="All" />
58+
</ItemGroup>
59+
60+
</Project>

0 commit comments

Comments
 (0)