Build / build (push) Canceled after 0s
Kein Runner auf der Gitea-Instanz konfiguriert — build-release.ps1 kapselt den dotnet-publish-Befehl aus dem letzten Commit als Ein-Zeiler-Aufruf (.\build-release.ps1), meldet Erfolg/Misserfolg und zeigt Pfad + Größe der fertigen exe. Der Gitea-Actions-Workflow bleibt bestehen, falls später doch ein Runner eingerichtet wird. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
29 lines
1011 B
PowerShell
29 lines
1011 B
PowerShell
<#
|
|
Baut MikroTik-Installer.exe als eigenständige Single-File-Anwendung für Windows x64.
|
|
Kein Gitea-Actions-Runner nötig - einfach lokal ausführen:
|
|
|
|
.\build-release.ps1
|
|
#>
|
|
|
|
$ErrorActionPreference = "Stop"
|
|
$root = $PSScriptRoot
|
|
|
|
Write-Host "Baue MikroTik Installer (Release, win-x64, self-contained) ..." -ForegroundColor Cyan
|
|
|
|
dotnet publish "$root\src\MikrotikInstaller.App\MikrotikInstaller.App.csproj" `
|
|
--configuration Release `
|
|
--runtime win-x64
|
|
|
|
$exePath = Join-Path $root "src\MikrotikInstaller.App\bin\Release\net8.0-windows\win-x64\publish\MikroTik-Installer.exe"
|
|
|
|
if (Test-Path $exePath) {
|
|
$sizeMb = [math]::Round((Get-Item $exePath).Length / 1MB, 1)
|
|
Write-Host ""
|
|
Write-Host "Fertig: $exePath ($sizeMb MB)" -ForegroundColor Green
|
|
Write-Host "Diese eine Datei kann direkt weitergegeben werden - keine Installation notwendig." -ForegroundColor Green
|
|
}
|
|
else {
|
|
Write-Host "Build fehlgeschlagen - exe wurde nicht gefunden." -ForegroundColor Red
|
|
exit 1
|
|
}
|