diff --git a/README.md b/README.md index 52916aa..fe57b7a 100644 --- a/README.md +++ b/README.md @@ -178,6 +178,8 @@ Die Anwendung läuft auf Windows Server im IIS. Das Betriebshandbuch Installation, neue Stände, Rückstieg, Plattform-Updates, Zugang und Fehlersuche. Das Paket dafür baut `npm run paket:windows`; an jedem Release dieses Repositoriums hängt es fertig gebaut (`.github/workflows/release.yml`). +Installationsanleitung und Betriebshandbuch liegen als PDF in `docs/` und im +Hauptordner jedes Pakets. **Intern, nicht in der Übergabe:** Der eigene Testbetrieb mit Docker steht in diff --git a/deploy/windows/aktualisieren.ps1 b/deploy/windows/aktualisieren.ps1 index a3dbe5a..318dacd 100644 --- a/deploy/windows/aktualisieren.ps1 +++ b/deploy/windows/aktualisieren.ps1 @@ -81,8 +81,10 @@ if ($fehlend.Count -gt 0) { throw "Unvollstaendige Konfiguration in ${Ziel}: $($ $port = [int]$app['PORT'] $url = $verwaltung['MIGRATE_DATABASE_URL'] +# Als reine Zeichenketten: Get-Content haengt jeder Zeile Eigenschaften wie +# PSPath an, und ConvertTo-Json schriebe sie mit in letztes-update.json. function Get-Version([string]$Datei) { - if (Test-Path -LiteralPath $Datei) { return @(Get-Content -LiteralPath $Datei -Encoding UTF8 | Where-Object { $_ -ne '' }) } + if (Test-Path -LiteralPath $Datei) { return @(Get-Content -LiteralPath $Datei -Encoding UTF8 | Where-Object { $_ -ne '' } | ForEach-Object { [string]$_ }) } return @() } diff --git a/uebergabe/anleitung/Betriebshandbuch_Alpenwerk_HR.pdf b/docs/Betriebshandbuch_Alpenwerk_HR.pdf similarity index 99% rename from uebergabe/anleitung/Betriebshandbuch_Alpenwerk_HR.pdf rename to docs/Betriebshandbuch_Alpenwerk_HR.pdf index 5725266..0ca7f5a 100644 Binary files a/uebergabe/anleitung/Betriebshandbuch_Alpenwerk_HR.pdf and b/docs/Betriebshandbuch_Alpenwerk_HR.pdf differ diff --git a/uebergabe/anleitung/Installationsanleitung_Alpenwerk_HR.pdf b/docs/Installationsanleitung_Alpenwerk_HR.pdf similarity index 99% rename from uebergabe/anleitung/Installationsanleitung_Alpenwerk_HR.pdf rename to docs/Installationsanleitung_Alpenwerk_HR.pdf index f7e8738..83aba44 100644 Binary files a/uebergabe/anleitung/Installationsanleitung_Alpenwerk_HR.pdf and b/docs/Installationsanleitung_Alpenwerk_HR.pdf differ diff --git a/scripts/windows-paket.mjs b/scripts/windows-paket.mjs index 58dfced..861bd45 100644 --- a/scripts/windows-paket.mjs +++ b/scripts/windows-paket.mjs @@ -108,6 +108,12 @@ cpSync("deploy/db-init/01-auth-attrappe.sql", join(app, "deploy/db-init/01-auth- // ── Betriebsskripte ─────────────────────────────────────────────────── cpSync("deploy/windows", join(ziel, "windows"), { recursive: true }); +// Installationsanleitung und Betriebshandbuch liegen als PDF im Hauptordner, +// damit sie beim Entpacken als Erstes zu sehen sind. +for (const datei of readdirSync("docs").filter((d) => d.endsWith(".pdf"))) { + cpSync(join("docs", datei), join(ziel, datei)); +} + writeFileSync( join(ziel, "VERSION.txt"), [ diff --git a/uebergabe/anleitung/pdf-bauen.mjs b/uebergabe/anleitung/pdf-bauen.mjs index e186794..58b11a2 100644 --- a/uebergabe/anleitung/pdf-bauen.mjs +++ b/uebergabe/anleitung/pdf-bauen.mjs @@ -1,4 +1,6 @@ // Baut Installationsanleitung und Betriebshandbuch als PDF im elycon-Layout. +// Die PDFs landen in docs/: von dort gehen sie in den Übergabestand und in den +// Hauptordner des Windows-Pakets (scripts/windows-paket.mjs). // // Aufruf: node uebergabe/anleitung/pdf-bauen.mjs (md2pdf selbst braucht bun, pandoc und Chrome) // @@ -74,6 +76,7 @@ for (const d of dokumente) { const temp = join(arbeit, `${d.name}.md`); writeFileSync(temp, md); execFileSync("bun", [md2pdf, temp], { cwd: dirname(md2pdf), stdio: "ignore" }); - copyFileSync(temp.replace(/\.md$/, ".pdf"), join(hier, `${d.name}.pdf`)); - console.log(`PDF: ${join(hier, `${d.name}.pdf`)}`); + const ausgabe = join(repo, "docs", `${d.name}.pdf`); + copyFileSync(temp.replace(/\.md$/, ".pdf"), ausgabe); + console.log(`PDF: ${ausgabe}`); }