Update executable names for beta and alpha paths.

This commit is contained in:
Patrick FIc
2025-09-09 15:47:31 -07:00
parent 9fdd88526c
commit 1c839ee3f8
11 changed files with 333 additions and 20 deletions

View File

@@ -0,0 +1,38 @@
# PowerShell script to set artifact naming based on version
param(
[string]$ConfigType = "imex"
)
# Read the package.json to get the version
$packageJsonPath = Join-Path $PSScriptRoot "..\package.json"
$packageJson = Get-Content $packageJsonPath | ConvertFrom-Json
$version = $packageJson.version
Write-Host "Current version: $version"
# Determine the artifact suffix based on the version
$artifactSuffix = ""
if ($version -match "alpha") {
$artifactSuffix = "alpha-${version}-"
Write-Host "Detected alpha version, setting suffix to: $artifactSuffix"
}
elseif ($version -match "beta") {
$artifactSuffix = "beta-${version}-"
Write-Host "Detected beta version, setting suffix to: $artifactSuffix"
}
else {
$artifactSuffix = ""
Write-Host "Detected release version, no suffix will be added"
}
# Set the environment variable
$env:ARTIFACT_SUFFIX = $artifactSuffix
# Export for the current session
[Environment]::SetEnvironmentVariable("ARTIFACT_SUFFIX", $artifactSuffix, "Process")
Write-Host "ARTIFACT_SUFFIX set to: '$env:ARTIFACT_SUFFIX'"
# Return the suffix for use in other scripts
return $artifactSuffix