generated from unoplatform/template
-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
build: Few build adjustments to reduce flakiness (#700)
Co-authored-by: Steve Bilogan <steve.bilogan@gmail.com>
- Loading branch information
1 parent
97bc94f
commit f622a0d
Showing
6 changed files
with
21 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,20 @@ | ||
<Project ToolsVersion="15.0"> | ||
<Import Project="$([MSBuild]::GetPathOfFileAbove('Directory.Build.targets', '$(MSBuildThisFileDirectory)../'))" /> | ||
<Import Project="Directory.UnoMetadata.targets" /> | ||
|
||
<!-- This is a workaround, should be removed when this issue is fixed: https://github.com/unoplatform/uno/issues/13167 --> | ||
<!-- Without this, the build gets flaky and sometimes fails with this error --> | ||
<!-- C:\hostedtoolcache\windows\dotnet\sdk\7.0.306\Sdks\NuGet.Build.Tasks.Pack\buildCrossTargeting\NuGet.Build.Tasks.Pack.targets(221,5): error NU5019: File not found: 'D:\a\1\s\src\library\Uno.Toolkit.Cupertino\bin\Uno.Toolkit.WinUI.Cupertino\Release\net7.0-ios\Uno.Toolkit.WinUI.Cupertino.uprimarker'. [D:\a\1\s\src\library\Uno.Toolkit.Cupertino\Uno.Toolkit.WinUI.Cupertino.csproj] --> | ||
<!-- Without this workaround target, what happens is that _UnoGeneratePriMarker was run before both _UnoAssetsGetCopyToPublishDirectory and finds ContentWithTargetPath being empty, so it does nothing --> | ||
<!-- Then later, _UnoAssetsGetCopyToPublishDirectory is run and ContentWithTargetPath is now added, and NuGet packaging now expects the uprimarker to be present --> | ||
<!-- Note that this error can go away with restarts, so it's a race condition --> | ||
<Target Name="_WorkaroundBuildFlakiness" | ||
BeforeTargets="_UnoGeneratePriMarker"> | ||
<ItemGroup> | ||
<ContentWithTargetPath Include="@(_TransitiveItemsToCopyToOutputDirectory)"> | ||
<TargetPath>%(TargetPath)</TargetPath> | ||
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory> | ||
</ContentWithTargetPath> | ||
</ItemGroup> | ||
</Target> | ||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters