1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-10-30 08:10:34 +01:00
bitwarden-browser/.github/scripts/macos/increment-version.ps1

8 lines
408 B
PowerShell
Raw Normal View History

2020-09-22 22:00:58 +02:00
$rootPath = $env:GITHUB_WORKSPACE;
2020-09-28 17:11:34 +02:00
$packagePath = "$rootPath\package.json";
2020-09-22 22:00:58 +02:00
$buildNumber = 100 + [int]$env:GITHUB_RUN_NUMBER;
2020-09-23 18:44:57 +02:00
Write-Output "Setting build number to $buildNumber";
2020-09-28 17:11:34 +02:00
$package = Get-Content -Raw -Path $packagePath | ConvertFrom-Json;
$package.build | Add-Member -MemberType NoteProperty -Name buildVersion -Value "$buildNumber";
$package | ConvertTo-Json -Depth 32 | Set-Content $packagePath;