docs: md 2 html for confluence
This commit is contained in:
15
scripts/md2html-seiten.ps1
Normal file
15
scripts/md2html-seiten.ps1
Normal file
@@ -0,0 +1,15 @@
|
||||
# Im Projekt-Root ausführen!
|
||||
$source = "..\docs"
|
||||
$target = ".\html-seiten"
|
||||
|
||||
# Zielordner anlegen
|
||||
if (!(Test-Path $target)) { New-Item -ItemType Directory -Path $target }
|
||||
|
||||
# Alle .md-Dateien rekursiv durchgehen
|
||||
Get-ChildItem -Path $source -Filter *.md -Recurse | ForEach-Object {
|
||||
$relPath = $_.FullName.Substring($source.Length)
|
||||
$outPath = Join-Path $target ($relPath -replace ".md$", ".html")
|
||||
$outDir = Split-Path $outPath
|
||||
if (!(Test-Path $outDir)) { New-Item -ItemType Directory -Path $outDir -Force }
|
||||
pandoc $_.FullName -o $outPath
|
||||
}
|
||||
Reference in New Issue
Block a user