Added extra check for template file ext. when replacing start menu

Changed links in README.md and Get.ps1 to use latest tagged release
This commit is contained in:
Raphire
2025-05-19 20:30:11 +02:00
parent 88f841a44b
commit 44c28bed43
3 changed files with 21 additions and 13 deletions

View File

@@ -645,13 +645,18 @@ function ReplaceStartMenu {
# Check if template bin file exists, return early if it doesn't
if (-not (Test-Path $startMenuTemplate)) {
Write-Host "Error: Unable to replace start menu, template start2.bin file not found" -ForegroundColor Red
Write-Host "Error: Unable to replace start menu, template file not found" -ForegroundColor Red
return
}
if ([IO.Path]::GetExtension($startMenuTemplate) -ne ".bin" ) {
Write-Host "Error: Unable to replace start menu, template file is not a valid .bin file" -ForegroundColor Red
return
}
# Check if bin file exists, return early if it doesn't
if (-not (Test-Path $startMenuBinFile)) {
Write-Host "Error: Unable to replace start menu for user $(GetUserName), template start2.bin file not found" -ForegroundColor Red
Write-Host "Error: Unable to replace start menu for user $(GetUserName), original start2.bin file not found" -ForegroundColor Red
return
}