NAME

doctor - private built-in command wrapper for Developer Dashboard

SYNOPSIS

d2 doctor [--fix]

DESCRIPTION

This private helper is staged under ~/.developer-dashboard/cli/dd/ so the public d2 entrypoint can stay a thin switchboard.

PURPOSE

This staged helper exposes d2 doctor and d2 doctor --fix. It is the CLI front end for runtime permission audits and repairs.

WHY IT EXISTS

It exists because runtime permission repair is a built-in operational command, but the actual audit and repair policy belongs in the doctor module rather than in the public switchboard.

WHEN TO USE

Use this file when changing doctor CLI flags or the handoff from the staged helper into the runtime permission audit code.

HOW TO USE

Users run d2 doctor to inspect or d2 doctor --fix to repair. The staged helper passes the request into the private runtime, which loads the doctor service and prints its report.

WHAT USES IT

It is used by operators hardening runtime permissions, by security smoke tests, and by integration flows that validate owner-only runtime modes.

EXAMPLES

Example 1:

d2 doctor

Run the public built-in command path that stages or re-enters this helper.

Example 2:

~/.developer-dashboard/cli/dd/doctor --help

Inspect the staged helper directly after d2 init or helper extraction has populated the home runtime.

Example 3:

prove -lv t/05-cli-smoke.t t/30-dashboard-loader.t

Rerun the focused staged-helper and thin-loader tests after changing helper dispatch behavior.

Example 4:

prove -lr t

Verify that the helper still behaves correctly inside the complete repository suite.