Welcome to mirror list, hosted at ThFree Co, Russian Federation.

Publishing.props « eng - github.com/dotnet/aspnetcore.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 0b01250bffab4d7a32874de601d236376f62ca99 (plain)
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
<Project>
  <PropertyGroup Condition=" HasTrailingSlash('$(ArtifactsDir)') ">
    <!-- The one use of ArtifactsDir in Publish.proj adds an additional slash, confusing itself. -->
    <ArtifactsDir>$(ArtifactsDir.Substring(0, $([MSBuild]::Subtract($(ArtifactsDir.Length), 1))))</ArtifactsDir>

    <PublishDependsOnTargets>$(PublishDependsOnTargets);_PublishInstallers</PublishDependsOnTargets>

    <_UploadPathRoot>aspnetcore</_UploadPathRoot>
  </PropertyGroup>

  <!-- $(InstallersOutputPath) and $(SymbolsOutputPath) are not defined. Root Directory.Build.props is not imported. -->
  <ItemGroup>
    <!-- Include our "loose" PDBs when publishing symbols. -->
    <FilesToPublishToSymbolServer Include="$(ArtifactsDir)\symbols\**\*.pdb" />

    <!-- Prepare for _PublishInstallers target. -->
    <_InstallersToPublish Remove="@(_InstallersToPublish)" />
    <_InstallersToPublish Include="$(ArtifactsDir)\packages\**\*.jar" UploadPathSegment="jar" />
    <_InstallersToPublish Include="$(ArtifactsDir)\packages\**\*.pom" UploadPathSegment="jar" />
    <_InstallersToPublish Include="$(ArtifactsDir)\packages\**\*.tgz" UploadPathSegment="npm" />
    <_InstallersToPublish Include="$(ArtifactsDir)\installers\**\*.deb" UploadPathSegment="Runtime" />
    <_InstallersToPublish Include="$(ArtifactsDir)\installers\**\*.exe" UploadPathSegment="Runtime" />
    <_InstallersToPublish Include="$(ArtifactsDir)\installers\**\*.msi" UploadPathSegment="Runtime" />
    <_InstallersToPublish Include="$(ArtifactsDir)\installers\**\*.rpm" UploadPathSegment="Runtime" />
    <_InstallersToPublish Include="$(ArtifactsDir)\installers\**\*.tar.gz" UploadPathSegment="Runtime" />
    <_InstallersToPublish Include="$(ArtifactsDir)\installers\**\*.version" UploadPathSegment="Runtime"
        Condition=" '$(PublishInstallerBaseVersion)' == 'true' " />
    <_InstallersToPublish Include="$(ArtifactsDir)\installers\**\*.wixlib" UploadPathSegment="Runtime" />
    <_InstallersToPublish Include="$(ArtifactsDir)\installers\**\*.zip" UploadPathSegment="Runtime" />
  </ItemGroup>

  <Target Name="_PublishInstallers">
    <!-- This target is defined in eng/targets/Packaging.targets and included in every C# and F# project. -->
    <MSBuild Projects="$(RepoRoot)src\Mvc\Mvc\src\Microsoft.AspNetCore.Mvc.csproj"
        Targets="_GetPackageVersionInfo"
        SkipNonexistentProjects="false">
      <Output TaskParameter="TargetOutputs" ItemName="_ResolvedPackageVersionInfo" />
    </MSBuild>

    <PropertyGroup>
      <_PackageVersion>@(_ResolvedPackageVersionInfo->'%(PackageVersion)')</_PackageVersion>
    </PropertyGroup>

    <ItemGroup>
      <!-- Do not push .nupkg files from Linux and macOS builds. They'll be packed up separately and signed on Windows. -->
      <ItemsToPushToBlobFeed Remove="@(ItemsToPushToBlobFeed)" Condition="'$(OS)' != 'Windows_NT'" />

      <ItemsToPushToBlobFeed Include="@(_InstallersToPublish)">
        <IsShipping>false</IsShipping>
        <ManifestArtifactData>NonShipping=true;ShipInstaller=dotnetcli</ManifestArtifactData>
        <PublishFlatContainer>true</PublishFlatContainer>
        <RelativeBlobPath>$(_UploadPathRoot)/%(_InstallersToPublish.UploadPathSegment)/$(_PackageVersion)/%(Filename)%(Extension)</RelativeBlobPath>
      </ItemsToPushToBlobFeed>
    </ItemGroup>
  </Target>
</Project>