Migrate all repos into monorepo context folders
Bahn: aisupport, Analyse-O2C-C2S, awesome-bahn-mcp-servers, beam-mcp,
Confluence_Bot, db-planet-mcp-server, O2C-Harness, project-audit,
Projekt-KIQ-HP, teamlandkarte-mcp
Dhive: Jury-Voting
Privat: CV, NoteGraph (NOTE: NoteGraph needs complete redo after consolidation)
Shared: AI-Orchestrator, OrgMyLife, power_skills_and_more
Shared/references: symphony (read-only)
Bahn repos remain available as independent remotes - this monorepo
pulls them in via subtree, the originals are untouched.
This commit is contained in:
@@ -0,0 +1,41 @@
|
||||
<#
|
||||
.SYNOPSIS
|
||||
Read specific Confluence pages by ID and save locally
|
||||
.USAGE
|
||||
powershell -ExecutionPolicy Bypass -File scripts/confluence-read.ps1 -PageIds "123,456,789"
|
||||
#>
|
||||
param([string]$PageIds = "")
|
||||
|
||||
. "$PSScriptRoot/../config.ps1"
|
||||
. "$PSScriptRoot/lib/confluence-api.ps1"
|
||||
|
||||
Write-Host "=== Confluence Page Reader ===" -ForegroundColor Cyan
|
||||
|
||||
if (-not $PageIds) {
|
||||
$PageIds = Read-Host "Enter page IDs (comma-separated)"
|
||||
}
|
||||
|
||||
$Ids = $PageIds -split ',' | ForEach-Object { $_.Trim() } | Where-Object { $_ }
|
||||
$OutPath = Join-Path $ProjectDir "data/pages"
|
||||
New-Item -ItemType Directory -Path $OutPath -Force | Out-Null
|
||||
|
||||
foreach ($Id in $Ids) {
|
||||
Write-Host ""
|
||||
Write-Host ">> Page $Id" -ForegroundColor Yellow
|
||||
$Page = Get-PageContent -PageId $Id
|
||||
if (-not $Page) { continue }
|
||||
|
||||
Write-Host " Title: $($Page.title) (v$($Page.version.number))" -ForegroundColor Green
|
||||
|
||||
$HtmlContent = ""
|
||||
if ($Page.body -and $Page.body.storage) { $HtmlContent = $Page.body.storage.value }
|
||||
$TextContent = Convert-HtmlToText $HtmlContent
|
||||
|
||||
$SafeTitle = $Page.title -replace '[\\/:*?"<>|]', '_'
|
||||
$HtmlContent | Out-File "$OutPath/$($Page.id)_$SafeTitle.html" -Encoding UTF8
|
||||
$TextContent | Out-File "$OutPath/$($Page.id)_$SafeTitle.md" -Encoding UTF8
|
||||
Write-Host " Saved ($($HtmlContent.Length) chars)"
|
||||
}
|
||||
|
||||
Write-Host ""
|
||||
Write-Host "Done! Files in $OutPath" -ForegroundColor Green
|
||||
Reference in New Issue
Block a user