Pular para o conteúdo
EN · PT

anchors doctor

X-ray of the ecosystem: systemic loose ends, health and maturity.

The ecosystem's health validator (QUALITY §5.2) — the GLOBAL view.
Unlike check (node against gate, incremental), doctor sweeps the map + the
Structure + the disk and hunts the SYSTEMIC loose ends no local gate sees:
map integrity (dead edges, phantom nodes), orphans (code without spec,
missing identity), loose layers, and gate coverage holes.
It PRESENTS and RECORDS, but does NOT block — it is diagnosis, run on demand.
With --fix, it creates what is missing: pipelines, git hooks, state labels and the
protection of the integration branch. It is IDEMPOTENT — in an already assembled
repository it changes nothing, and each repair checks before acting. Run it without asking
for authorization: it is the environment preparation step, not a project
change.
Terminal window
anchors doctor [flags]
Flag Padrão O que faz
--check-pipelines exits with 1 if any Anchors pipeline is out of date (so CI can self-verify)
--fix creates what is missing in the github mode environment (pipelines, labels, branch protection). IDEMPOTENT: in an already set-up repository it changes nothing, and it is safe to always run
--map path to the map
--root . project root

Comandos da mesma família — o que distingue cada um:

Comando O que faz
anchors doctor X-ray of the ecosystem: systemic loose ends, health and maturity
anchors audit Dossier of one file’s pending items (gates + doctor), for batch fixing
anchors status Where the project stands in the cycle, and what the next step is
anchors task-status The round’s report: what is delivered, what remains, and what comes next
anchors compliance The state of each regulatory duty: how many nodes subject, how many comply
anchors governs Show who each guide governs (and how many) — sizes the audit per guide





Enquanto o check avalia gates pontuais, o anchors doctor fornece um raio-X global de todo o ecossistema.


Terminal window
# Roda diagnóstico de saúde padrão
anchors doctor
# Roda com detalhamento diagnóstico completo
anchors doctor --verbose
  1. Artefatos Órfãos: Specs sem código implementado ou testes que verificam regras já deletadas.
  2. Colisão de Códigos de Identidade: Códigos duplicados (ex: AUTH-B01) declarados em dois arquivos diferentes.
  3. Deriva Arquitetural: Divergências entre as fronteiras de camadas declaradas em anchors.yaml e as importações reais.
  4. Buracos de Cobertura: Camadas regidas que caíram abaixo do nível de maturidade exigido.

Quando um arquivo ou módulo específico falha em vários gates, use o audit para gerar a lista de correção:

Terminal window
anchors audit src/services/billing/invoice.spec.md

Ele gera um dossiê unificado com cada cenário ausente, asserção quebrada, dependência obsoleta e violação de camada daquela unidade.