From 580d663d1a4b58b8324bf41c7297b3043cd93a1f Mon Sep 17 00:00:00 2001
From: ValueOn AG
Date: Sun, 5 Apr 2026 23:47:23 +0200
Subject: [PATCH] docs: add doc-sync cursor rule to wiki, integrate install
instructions in README
Made-with: Cursor
---
README.md | 29 +++++++++++++++++++++++++++++
TOPICS.md | 1 +
d-guides/doc-sync.mdc | 32 ++++++++++++++++++++++++++++++++
3 files changed, 62 insertions(+)
create mode 100644 d-guides/doc-sync.mdc
diff --git a/README.md b/README.md
index 944458a..d164dde 100644
--- a/README.md
+++ b/README.md
@@ -72,6 +72,35 @@ b-reference/
---
+## Cursor-Regel: Doc-Sync
+
+Eine Cursor-Rule sorgt dafür, dass der AI-Assistent bei konzeptionellen Code-Änderungen automatisch an die Wiki-Pflege erinnert.
+
+**Datei:** `@poweron/.cursor/rules/doc-sync.mdc` (Quelle: `wiki/d-guides/doc-sync.mdc`)
+
+Falls die Regel lokal noch nicht existiert, kopiere sie:
+
+```powershell
+# Prüfen und kopieren (PowerShell)
+$src = "wiki\d-guides\doc-sync.mdc"
+$dst = ".cursor\rules\doc-sync.mdc"
+if (-not (Test-Path $dst)) {
+ New-Item -ItemType Directory -Path ".cursor\rules" -Force | Out-Null
+ Copy-Item $src $dst
+ Write-Host "doc-sync.mdc installiert"
+} else {
+ Write-Host "doc-sync.mdc bereits vorhanden"
+}
+```
+
+**Was die Regel tut:**
+- Erinnert bei Änderungen an API, Domain-Logik, Security, RBAC, Navigation, Features, Billing
+- Während Arbeit: `c-work//.md` pflegen
+- Bei Abschluss: betroffene `b-reference/` Seite + `TOPICS.md` aktualisieren
+- Kein Doku-Zwang bei reinen Refactors, Formatting oder Test-only Changes
+
+---
+
## Für AI-Assistenten
**Immer zuerst laden:** `TOPICS.md` -- dort steht, welche Datei für welches Thema massgeblich ist.
diff --git a/TOPICS.md b/TOPICS.md
index 6a939d3..5e61803 100644
--- a/TOPICS.md
+++ b/TOPICS.md
@@ -43,3 +43,4 @@ Lade immer zuerst diese Datei. Dann gezielt die passende(n) Referenz-Datei(en).
| Testing-Strategie | d-guides/testing-strategy.md | Testpyramide, AC-Format, Test-Pfade |
| Deployment | d-guides/deployment.md | Release-Prozess, Environments |
| Dev-Setup | d-guides/dev-setup.md | Lokale Umgebung starten |
+| Doc-Sync Cursor-Rule | d-guides/doc-sync.mdc | Cursor-Regel installieren, Doku-Workflow |
diff --git a/d-guides/doc-sync.mdc b/d-guides/doc-sync.mdc
new file mode 100644
index 0000000..3ff3bb2
--- /dev/null
+++ b/d-guides/doc-sync.mdc
@@ -0,0 +1,32 @@
+---
+description: Reminder to update wiki documentation when making conceptual or structural code changes
+alwaysApply: true
+---
+
+# Documentation Sync
+
+When a code change touches any of these areas, remind the user to update the wiki:
+
+- Public API endpoints (new/changed/removed routes)
+- Domain logic flow (how data moves through services)
+- Security boundaries (neutralization, auth, encryption)
+- RBAC model (roles, permissions, access rules)
+- Navigation / routing structure
+- Feature boundaries (new feature module, moved responsibilities)
+- Billing / subscription logic
+
+## During active work
+
+Update the working document in `wiki/c-work//.md` (Kanban: 1-plan → 2-build → 3-validate → 4-done).
+
+## When work is done (merged/released)
+
+- Update the affected canonical page in `wiki/b-reference/`
+- Set `lastReviewed` and `verifiedAgainst` in the page header
+- Check if `wiki/TOPICS.md` needs a new or changed entry
+
+## Skip documentation for
+
+- Pure refactors without behavior change
+- Formatting, linting, dependency bumps
+- Test-only changes