-
Notifications
You must be signed in to change notification settings - Fork 1.1k
/
Copy pathmerge-asset-manifests.proj
33 lines (26 loc) · 1.36 KB
/
merge-asset-manifests.proj
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
<Project Sdk="Microsoft.Build.NoTargets">
<PropertyGroup>
<TargetFramework>$(NetCurrent)</TargetFramework>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="$(TasksDir)Microsoft.DotNet.UnifiedBuild.Tasks\Microsoft.DotNet.UnifiedBuild.Tasks.csproj" />
</ItemGroup>
<!-- Create a merge manifest from the individual repository manifest files. -->
<UsingTask TaskName="Microsoft.DotNet.UnifiedBuild.Tasks.MergeAssetManifests" AssemblyFile="$(MicrosoftDotNetUnifiedBuildTasksAssembly)" TaskFactory="TaskHostFactory" />
<Target Name="MergeAssetManifests" BeforeTargets="Build">
<ItemGroup>
<RepoAssetManifest Include="$(AssetManifestsIntermediateDir)**\*.xml" />
</ItemGroup>
<Error Text="Couldn't find any repository asset manifest file. Make sure to build the repositories before invoking this target." Condition="'@(RepoAssetManifest)' == ''" />
<!-- It's OK for the VmrBuildNumber to be empty -->
<Microsoft.DotNet.UnifiedBuild.Tasks.MergeAssetManifests
AssetManifest="@(RepoAssetManifest)"
MergedAssetManifestOutputPath="$(MergedAssetManifestOutputPath)"
VmrBuildNumber="$(BUILD_BUILDNUMBER)"
VerticalName="$(VerticalName)" />
<!-- Mark the artifact so that it gets binplaced. -->
<ItemGroup>
<BinPlaceFile Include="$(MergedAssetManifestOutputPath)" />
</ItemGroup>
</Target>
</Project>