Skip to content

Commit

Permalink
Updated the output
Browse files Browse the repository at this point in the history
  • Loading branch information
rajbos committed Nov 6, 2023
1 parent 61db55b commit bcdb3a7
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/handle-versioning-accross-branches.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,3 +76,7 @@ jobs:
}
Write-Host "Highest version: [$($highestVersion.Major).$($highestVersion.Minor).$($highestVersion.Patch)]"
# show the highest version number in GitHub by writing to the job summary file
Set-Content -Path $env:GITHUB_STEP_SUMMARY -Value "Highest version of the extension: [$($lastVersion.version | ConvertFrom-Json)]"
Set-Content -Path $env:GITHUB_STEP_SUMMARY -Value "Highest version of the PR check extension: [$($highestVersion.Major).$($highestVersion.Minor).$($highestVersion.Patch)]"
10 changes: 10 additions & 0 deletions make.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -277,6 +277,16 @@ if ("build" -eq $command) {
# delete all files with the name RobBos.GHAzDoWidget-DEV*.vsix
Get-ChildItem -Path .\ -Filter $extensionPrefix*.vsix | Remove-Item -Force

# get the last updated version for this extension from the server to make sure we are rolling forward
$output = $(tfx extension show --token $env:AZURE_DEVOPS_PAT --vsix $vsix --publisher "RobBos" --extension-id "GHAzDoWidget-DEV" --output json | ConvertFrom-Json)
$lastVersion = ($output.versions | Sort-Object -Property lastUpdated -Descending)[0]
Write-Host "Last version: [$($lastVersion.version)] from server"
# overwrite the version in the json file
$json = Get-Content .\vss-extension-dev.json | ConvertFrom-Json
$json.version = $lastVersion
# write the json file back
$json | ConvertTo-Json | Set-Content .\vss-extension-dev.json

# build the task
# todo: up the version number
Set-Location .\dependencyReviewTask
Expand Down

0 comments on commit bcdb3a7

Please sign in to comment.