Skip to content

Rules a machine decides, wired, tested and CI-blocking

Every rule is a portable Markdown object with front matter; a rule the tool enforces names its validator, the commands that dispatch it and the tests that prove it, and doctor walks that chain from the source, refusing a validator nobody declares and a declaration nothing runs; a blocking violation stops the command and an advisory one is reported.

A rule is enforced when a validator decides it, a command runs it, a test proves it and CI blocks on it; anything less is documentation, and the tool knows the difference.

status
stable

What it does

The effective rule set is the vendored baseline the tool ships plus the rules this repository wrote, resolved as a dependency graph: a missing dependency, a cycle or two rules claiming one identity is an error, and a set that does not resolve is not applied at all. A rule's class is blocking or advisory and there is no third; the class is read at dispatch time and is what routes a finding, so changing one word in a rule file changes whether majordomus check exits zero — and a test asserts exactly that.

majordomus doctor reads the source rather than a rule's description of itself: the validator function must exist, the commands the rule names must dispatch it, a blocking rule must be able to exit non-zero, a test must prove it, and CI must run that test without swallowing its exit code. A validator no rule declares is enforcement running under no rule, and fails.

What it does not do

A rule without a validator is normative for whoever reads it and enforced by nobody, and it says so; the tool does not pretend otherwise. There is no severity ladder, no baseline and no override: a project rule may add a constraint and may never weaken a vendored one.

The capabilities behind it

The capability modules of the executable this feature names, each with the capabilities it composes. The command line, the HTTP route, the MCP tool and the reference beside every row are projections of one declaration, not four registrations.

Health health behaviorally verified

Whether what this process serves is healthy, decided by the engines that already decide it: the index's diagnostics, the registry builder, the benchmark projection's coverage and the comparison `generate --check` makes. No check here has an opinion of its own.

apps/majordomus-cli/src/capability/builtin/health.rs

The commands that run it

  • majordomus rules inspect

    The effective rule set, vendored baseline plus project rules.

  • majordomus doctrine inspect · read-only

    What rules are enforced, by what, and whether each one is actually wired.

  • majordomus doctor inspect · read-only

    Is Majordomus itself healthy, and is every enforcement it declares actually wired here?

  • majordomus check verify · read-only

    Is the current task still consistent with its policy, its scope and this checkout?

  • majordomus watch inspect · read-only

    What has drifted since the last update — policy, projections, state, retention.

The objects it is made of

Kinds of the layer. Each is a schema, a source class and a file on disk; the number beside it is what this repository holds today, counted at build time.

  • rule109

What it answers

Operational moments from the Why catalogue that name one of this feature's mechanisms. Nothing here was assigned: a moment appears because it names a rule, a command, a capability or a claim this feature also names.

The rules that hold it

  • blockingA new enforced rule is a doctrine, not an inline checkproject.rule-is-a-doctrine
  • blockingDoctrine wiring integritymajordomus.doctrine-wiring-integrity
  • blockingEnforcement wiringmajordomus.enforcement-wiring
  • blockingRule package integritymajordomus.rule-package-integrity
  • blockingNo claim without a testproject.no-claim-without-test

What is guaranteed

Executable use cases