77 $architecture = ' current' ,
88 [switch ]$Clippy ,
99 [switch ]$SkipBuild ,
10- [ValidateSet (' msix' , ' msixbundle' , ' tgz' , ' zip' )]
10+ [ValidateSet (' msix' , ' msix-private ' , ' msixbundle' , ' tgz' , ' zip' )]
1111 $packageType ,
1212 [switch ]$Test ,
1313 [switch ]$GetPackageVersion ,
@@ -424,7 +424,7 @@ if ($packageType -eq 'msixbundle') {
424424 $msixPath = Join-Path $PSScriptRoot ' bin' ' msix'
425425 & $makeappx bundle / d $msixPath / p " $PSScriptRoot \bin\$packageName .msixbundle"
426426 return
427- } elseif ($packageType -eq ' msix' ) {
427+ } elseif ($packageType -eq ' msix' -or $packageType -eq ' msix-private ' ) {
428428 if (! $IsWindows ) {
429429 throw " MSIX is only supported on Windows"
430430 }
@@ -433,21 +433,34 @@ if ($packageType -eq 'msixbundle') {
433433 throw ' MSIX requires a specific architecture'
434434 }
435435
436+ $isPrivate = $packageType -eq ' msix-private'
437+
436438 $makeappx = Find-MakeAppx
437439 $makepri = Get-Item (Join-Path $makeappx.Directory " makepri.exe" ) - ErrorAction Stop
438440 $displayName = " DesiredStateConfiguration"
439441 $isPreview = $productVersion -like ' *-*'
440442 $productName = " DesiredStateConfiguration"
441443 if ($isPreview ) {
442444 Write-Verbose - Verbose " Preview version detected"
443- $productName += " -Preview"
445+ if ($isPrivate ) {
446+ $productName += " -Private"
447+ }
448+ else {
449+ $productName += " -Preview"
450+ }
444451 # save preview number
445452 $previewNumber = $productVersion -replace ' .*?-[a-z]+\.([0-9]+)' , ' $1'
446453 # remove label from version
447454 $productVersion = $productVersion.Split (' -' )[0 ]
448455 # replace revision number with preview number
449456 $productVersion = $productVersion -replace ' (\d+)$' , " $previewNumber .0"
450- $displayName += " -Preview"
457+
458+ if ($isPrivate ) {
459+ $displayName += " -Private"
460+ }
461+ else {
462+ $displayName += " -Preview"
463+ }
451464 }
452465 Write-Verbose - Verbose " Product version is $productVersion "
453466 $arch = if ($architecture -eq ' aarch64-pc-windows-msvc' ) { ' arm64' } else { ' x64' }
@@ -519,7 +532,7 @@ if ($packageType -eq 'msixbundle') {
519532 throw " Failed to create msix package"
520533 }
521534
522- Write-Host - ForegroundColor Green " `n MSIX package is created at $packageName .msix "
535+ Write-Host - ForegroundColor Green " `n MSIX package is created at $packageName "
523536} elseif ($packageType -eq ' zip' ) {
524537 $zipTarget = Join-Path $PSScriptRoot ' bin' $architecture ' zip'
525538 if (Test-Path $zipTarget ) {
0 commit comments