Skip to content

Commit ba2279c

Browse files
committed
⬆️ Bump files with dotnet-file sync
# devlooped/oss - Enable package pruning in Directory.Build.props devlooped/oss@0ff8b7b
1 parent 48ddb8c commit ba2279c

File tree

3 files changed

+16
-3
lines changed

3 files changed

+16
-3
lines changed

.netconfig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,8 @@
9292
weak
9393
[file "src/Directory.Build.props"]
9494
url = https://github.com/devlooped/oss/blob/main/src/Directory.Build.props
95-
sha = 95b338b9780de6b8ed11f060fed2d300f136ec60
96-
etag = 5e73ffebd7aef6fecae5a73d4fb044bf46f3a593ee2858ff1648d9c337e546ad
95+
sha = 0ff8b7b79a82112678326d1dc5543ed890311366
96+
etag = 3ebde0a8630d526b80f15801179116e17a857ff880a4442e7db7b075efa4fd63
9797
weak
9898
[file "src/Directory.Build.targets"]
9999
url = https://github.com/devlooped/oss/blob/main/src/Directory.Build.targets

readme.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ while (books.MoveNext())
9292
<!-- sponsors.md -->
9393
[![Clarius Org](https://avatars.githubusercontent.com/u/71888636?v=4&s=39 "Clarius Org")](https://github.com/clarius)
9494
[![MFB Technologies, Inc.](https://avatars.githubusercontent.com/u/87181630?v=4&s=39 "MFB Technologies, Inc.")](https://github.com/MFB-Technologies-Inc)
95+
[![SandRock](https://avatars.githubusercontent.com/u/321868?u=99e50a714276c43ae820632f1da88cb71632ec97&v=4&s=39 "SandRock")](https://github.com/sandrock)
9596
[![DRIVE.NET, Inc.](https://avatars.githubusercontent.com/u/15047123?v=4&s=39 "DRIVE.NET, Inc.")](https://github.com/drivenet)
9697
[![Keith Pickford](https://avatars.githubusercontent.com/u/16598898?u=64416b80caf7092a885f60bb31612270bffc9598&v=4&s=39 "Keith Pickford")](https://github.com/Keflon)
9798
[![Thomas Bolon](https://avatars.githubusercontent.com/u/127185?u=7f50babfc888675e37feb80851a4e9708f573386&v=4&s=39 "Thomas Bolon")](https://github.com/tbolon)
@@ -119,6 +120,7 @@ while (books.MoveNext())
119120
[![](https://avatars.githubusercontent.com/devlooped-user?s=39 "")](https://github.com/henkmartijn)
120121
[![torutek](https://avatars.githubusercontent.com/u/33917059?v=4&s=39 "torutek")](https://github.com/torutek)
121122
[![mccaffers](https://avatars.githubusercontent.com/u/16667079?u=739e110e62a75870c981640447efa5eb2cb3bc8f&v=4&s=39 "mccaffers")](https://github.com/mccaffers)
123+
[![ADS Fund](https://avatars.githubusercontent.com/u/202042116?v=4&s=39 "ADS Fund")](https://github.com/ADS-Fund)
122124

123125

124126
<!-- sponsors.md -->

src/Directory.Build.props

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<Project>
1+
<Project TreatAsLocalProperty="VersionPrefix">
22
<!-- To extend/change the defaults, create a Directory.props alongside this file -->
33

44
<PropertyGroup Label="CI" Condition="'$(CI)' == ''">
@@ -45,6 +45,8 @@
4545
<GeneratePathProperty>true</GeneratePathProperty>
4646
<!-- Avoid warnings for test projects when we run dotnet pack on the whole solution. -->
4747
<WarnOnPackingNonPackableProject>false</WarnOnPackingNonPackableProject>
48+
<!-- See https://learn.microsoft.com/en-us/nuget/consume-packages/package-references-in-project-files#prunepackagereference-specification -->
49+
<RestoreEnablePackagePruning>true</RestoreEnablePackagePruning>
4850
</PropertyGroup>
4951

5052
<PropertyGroup Label="Build">
@@ -136,6 +138,15 @@
136138
<VersionSuffix Condition="!$(VersionLabel.Contains('refs/tags/'))">$(_VersionLabel)</VersionSuffix>
137139
<!-- Special case for tags, the label is actually the version. Backs compat since passed-in value overrides MSBuild-set one -->
138140
<Version Condition="$(VersionLabel.Contains('refs/tags/'))">$(_VersionLabel)</Version>
141+
142+
<!-- In order for latest from main/master to always be greatest when using -prerelease switch on install/run,
143+
we change the scheme as follows:
144+
- main/master remain as today: VersionPrefix: 42.42.${{ github.run_number }} (from yaml)
145+
- others: VersionPrefix: 42.42.0-[label].${{ github.run_number }}
146+
-->
147+
<IsMaster Condition="$(VersionLabel.Contains('refs/heads/main')) or $(VersionLabel.Contains('refs/heads/master'))">true</IsMaster>
148+
<VersionPrefix Condition="'$(IsMaster)' != 'true'">42.42.0</VersionPrefix>
149+
<VersionSuffix Condition="'$(IsMaster)' != 'true'">$(VersionSuffix).$(GITHUB_RUN_NUMBER)</VersionSuffix>
139150
</PropertyGroup>
140151

141152
<ItemGroup Label="ThisAssembly.Project">

0 commit comments

Comments
 (0)