18 lines
434 B
PowerShell
18 lines
434 B
PowerShell
#Requires -Version 5.1
|
|
<#
|
|
.SYNOPSIS
|
|
Pack JSON into ysbin.ypf (restores ysbin.ypf.bak first, then runs ysbin-patch pack).
|
|
|
|
.EXAMPLE
|
|
.\scripts\pack_ysbin.ps1
|
|
ysbin-patch.bat pack
|
|
#>
|
|
param()
|
|
|
|
$ErrorActionPreference = 'Stop'
|
|
$patch = Join-Path (Split-Path $PSScriptRoot -Parent) 'ysbin-patch.ps1'
|
|
if (-not (Test-Path -LiteralPath $patch)) {
|
|
throw "Missing $patch"
|
|
}
|
|
& $patch pack
|
|
if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }
|