Linter rule: mandatory tags/metadata on elements (e.g. teamOwner) #3224
miarrieta-coopenae
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Problem
In larger organizations, teams want to enforce ownership/governance metadata across the architecture model — for example, requiring every element (or every element of a given kind, like
service) to carry ateamOwnertag. Today nothing in LikeC4 enforces this: a missing tag is silently allowed, so ownership data drifts and becomes unreliable over time.Proposal
Add an opt-in lint rule, configurable per project in
likec4.config.json, e.g.:{ "lint": { "mandatoryTags": [ { "tag": "teamOwner", "kinds": ["service", "system"] } ] } }kindsis omitted, the tag is required on all elements.specification { tag teamOwner { ... } }(reusing the existing declared-tag mechanism, rather than free-form strings).likec4 validate/ CI, using the existingValidationRegistrypipeline — no separate lint command needed.Open questions
metadatakeys (free-form key/value), not just declaredtags?kinds(e.g. by tag combination, by folder/namespace)?Happy to help draft an implementation plan if this direction sounds good.
All reactions