This commit is contained in:
Maxim Lobanov
2020-12-09 11:48:13 +03:00
parent 21cbc1e8ca
commit f4ff9fb93d
4 changed files with 29 additions and 33 deletions

View File

@@ -37,7 +37,7 @@ if ($VersionsToBuild) {
$availableVersions = $VersionsToBuild -join ","
$toolVersions = $availableVersions.Replace(",",", ")
Write-Host "The following versions are available to build:`n$toolVersions"
Write-Output "##vso[task.setvariable variable=TOOL_VERSIONS;isOutput=true]$toolVersions"
Write-Host "##vso[task.setvariable variable=TOOL_VERSIONS;isOutput=true]$toolVersions"
} else {
Write-Host "There aren't versions to build"
}

View File

@@ -27,10 +27,7 @@ param(
[ValidateNotNullOrEmpty()]
[System.String]$ToolVersion,
[Parameter(Mandatory)]
[ValidateNotNullOrEmpty()]
[System.String]$PipelineUrl,
[System.String]$ImageUrl = 'https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png'
)
@@ -38,7 +35,10 @@ param(
Import-Module $PSScriptRoot/helpers.psm1 -DisableNameChecking
# Create JSON body
$text = "The following versions of '$toolName' are available to upload: $toolVersion\nLink to the pipeline: $pipelineUrl"
$text = "The following versions of '$toolName' are available to upload: $toolVersion"
if ($PipelineUrl) {
$text += "\nLink to the pipeline: $pipelineUrl"
}
$jsonBodyMessage = @"
{
"blocks": [