feat(cli): add specify doctor command for project health validation#1893
Closed
mvanhorn wants to merge 1 commit intogithub:mainfrom
Closed
feat(cli): add specify doctor command for project health validation#1893mvanhorn wants to merge 1 commit intogithub:mainfrom
mvanhorn wants to merge 1 commit intogithub:mainfrom
Conversation
Adds a new CLI command that validates the internal health of a spec-kit project: template integrity, agent configuration consistency, script permissions, constitution existence, and feature artifact completeness. Outputs a health score from 0-10 with pass/warn/fail for each check. Options: --json (CI-friendly output), --fix (auto-fix permissions), --verbose (detailed output) Includes 16 unit tests covering all health check functions. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
mnriem
requested changes
Mar 18, 2026
Collaborator
mnriem
left a comment
There was a problem hiding this comment.
Can you deliver this as an extension? See https://github.com/github/spec-kit/tree/main/extensions
Contributor
Author
|
Got it - will repackage these as an extension. Closing these and will submit a PR with a bundled extension that provides resume, doctor, and validate as extension commands. |
mvanhorn
added a commit
to mvanhorn/spec-kit
that referenced
this pull request
Mar 18, 2026
…lidate Packages three SDD utility commands as an extension per maintainer feedback on PRs github#1892, github#1893, github#1894. Commands: - speckit.speckit-utils.resume: detect feature state, suggest next command - speckit.speckit-utils.doctor: validate project health (templates, agent config, scripts, constitution, feature artifacts) - speckit.speckit-utils.validate: verify spec-to-task traceability and check that completed tasks produced expected files Hooks into after_specify (doctor) and after_plan (validate) optionally. This contribution was developed with AI assistance (Claude Code). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This was referenced Mar 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
specify doctor- a CLI command that validates the internal health of a spec-kit project. Goes beyondspecify check(which only validates external tool installations) to validate the project itself: templates, agent config, scripts, constitution, and feature artifacts.Why this matters
Users hit confusing errors when their spec-kit project is misconfigured, and there's no diagnostic tool to help them.
All of these share a common diagnostic gap: no way to validate the project's internal configuration without manually inspecting files.
Changes
specify doctorcommand to the CLI (src/specify_cli/__init__.py)_check_templates(),_check_agent_config(),_check_scripts(),_check_constitution(),_check_features().specify/init-options.jsonand verifies the agent directory and command filesspecs/NNN-*/for complete artifact sets (spec, plan, tasks)--json(machine-readable CI output, exits 1 on failures),--fix(auto-fix script permissions),--verbosetests/test_doctor.pyTesting
Sample output:
This contribution was developed with AI assistance (Claude Code).