feat: add openspec binary dependency check to doctor - #133
Merged
Conversation
- checkOpenspecBinary() probes exec.LookPath("openspec") and best-effort
parses `openspec --version`; never errors, degrades to found/no-version.
- doctorClaude attaches Dependencies to DoctorResult, downgrades status to
warning and recommends `openspec init` when missing, prints a
Dependencies section in prose output.
- doctorInstall gains an External Dependencies section and a JSON branch
(previously --json was silently ignored).
- Additive-only JSON fields; existing DoctorResult/InstallationInfo fields
unchanged.
- Add unit tests for checkOpenspecBinary (present+parseable,
present+unparseable, present+failing --version, absent) and additive-field
guards for doctor claude/install --json.
- Update site/features.json and proposal.md release note.
(#132)
Deploying specsync with
|
| Latest commit: |
c62e063
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://4151a688.specsync.pages.dev |
| Branch Preview URL: | https://feat-doctor-checks-openspec.specsync.pages.dev |
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.
Closes #132
specsync hard-depends on the
openspecCLI binary at runtime, butspecsync doctornever checked whether it was actually installed — a user could skipopenspec initand hit a bare "executable file not found" failure deep inside an unrelated command instead of an upfront diagnostic.checkOpenspecBinary(): probesexec.LookPath("openspec"), best-effort parsesopenspec --version. Never errors — "not found" and "unparseable version" are both reportable states.doctor claude: surfaces a missing binary as a warning with anopenspec initrecommendation; additive-only JSON fields.doctor install: gains an "External Dependencies" section, and its--jsonflag — previously silently ignored — now actually emits JSON.--version, and absent.See
openspec/changes/doctor-checks-openspec-binary/for the full proposal/design/spec.