Skip to content

Commit 3aad49b

Browse files
Merge pull request #30004 from adiaaida/renameProductVersion (#30124)
Duplicate productVersion.txt with repo-specific name
1 parent 2cc9c2d commit 3aad49b

File tree

1 file changed

+14
-2
lines changed

1 file changed

+14
-2
lines changed

eng/Publishing.props

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,9 @@
88

99
<_UploadPathRoot>aspnetcore</_UploadPathRoot>
1010
<ProductVersionFileName>productVersion.txt</ProductVersionFileName>
11+
<RepoProductVersionFileName>$(_UploadPathRoot)-$(ProductVersionFileName)</RepoProductVersionFileName>
1112
<ProductVersionFileLocation>$(ArtifactsShippingPackagesDir)$(ProductVersionFileName)</ProductVersionFileLocation>
13+
<RepoProductVersionFileLocation>$(ArtifactsShippingPackagesDir)$(RepoProductVersionFileName)</RepoProductVersionFileLocation>
1214
</PropertyGroup>
1315

1416
<!-- $(InstallersOutputPath), $(SymbolsOutputPath), and $(ChecksumExtensions) are not defined. Root Directory.Build.props is not imported. -->
@@ -33,7 +35,7 @@
3335
<_ChecksumsToPublish Include="$(ArtifactsDir)**\*.sha512" />
3436
</ItemGroup>
3537

36-
<Target
38+
<Target
3739
Name="_PublishInstallersAndChecksumsAndProductVersion"
3840
DependsOnTargets="_WriteProductVersionFile">
3941
<!--
@@ -78,10 +80,15 @@
7880
<PublishFlatContainer>true</PublishFlatContainer>
7981
<RelativeBlobPath>$(_UploadPathRoot)/Runtime/$(_PackageVersion)/$(ProductVersionFileName)</RelativeBlobPath>
8082
</ItemsToPushToBlobFeed>
83+
84+
<ItemsToPushToBlobFeed Include="$(RepoProductVersionFileLocation)" Condition=" '$(PublishInstallerBaseVersion)' == 'true'">
85+
<PublishFlatContainer>true</PublishFlatContainer>
86+
<RelativeBlobPath>$(_UploadPathRoot)/Runtime/$(_PackageVersion)/$(RepoProductVersionFileName)</RelativeBlobPath>
87+
</ItemsToPushToBlobFeed>
8188
</ItemGroup>
8289
</Target>
8390

84-
<Target
91+
<Target
8592
Name="_WriteProductVersionFile"
8693
Condition=" '$(PublishInstallerBaseVersion)' == 'true'">
8794
<!--
@@ -106,5 +113,10 @@
106113
Lines="$(_ProductVersion)"
107114
Overwrite="true"
108115
Encoding="ASCII" />
116+
<WriteLinesToFile
117+
File="$(RepoProductVersionFileLocation)"
118+
Lines="$(_ProductVersion)"
119+
Overwrite="true"
120+
Encoding="ASCII" />
109121
</Target>
110122
</Project>

0 commit comments

Comments
 (0)