|
@@ -1,6 +1,7 @@
|
|
|
param (
|
|
param (
|
|
|
[switch]$doNotBuildBaseFap = $false,
|
|
[switch]$doNotBuildBaseFap = $false,
|
|
|
- [switch]$buildCustomFontFap = $false
|
|
|
|
|
|
|
+ [switch]$buildCustomFontFap = $false,
|
|
|
|
|
+ [switch]$doNotClearBuildFolder = $false
|
|
|
)
|
|
)
|
|
|
|
|
|
|
|
function Get-LatestDirectory {
|
|
function Get-LatestDirectory {
|
|
@@ -36,7 +37,7 @@ Push-Location $PSScriptRoot
|
|
|
|
|
|
|
|
if (!(Test-Path -PathType Container "build")) {
|
|
if (!(Test-Path -PathType Container "build")) {
|
|
|
New-Item -ItemType Directory -Path "build"
|
|
New-Item -ItemType Directory -Path "build"
|
|
|
-} else {
|
|
|
|
|
|
|
+} elseif (!$doNotClearBuildFolder) {
|
|
|
Remove-Item "build/*" -Recurse -Force
|
|
Remove-Item "build/*" -Recurse -Force
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -141,4 +142,12 @@ if ($buildCustomFontFap -eq $true) {
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+$checksum_file = 'build/checksums.sha256'
|
|
|
|
|
+New-Item $checksum_file -ItemType File -Force
|
|
|
|
|
+Get-ChildItem -Path 'build/*.fap' | ForEach-Object {
|
|
|
|
|
+ $checksum = (Get-FileHash $_ -Algorithm SHA256).Hash.ToLower()
|
|
|
|
|
+ $filename = $_.Name
|
|
|
|
|
+ "$checksum $filename" >> $checksum_file
|
|
|
|
|
+}
|
|
|
|
|
+
|
|
|
Pop-Location
|
|
Pop-Location
|