/repo-health:env-doctorfrom repo-health
Use when a project will not install, build, start or pass tests on this machine; on a first clone or onboarding; when an error smells of setup (wrong runtime version, missing tool, missing env var, port in use, service not running); or when asked to check, diagnose or doctor the environment. Read-only: compares what the repo declares with what this machine has and gives one fix per gap.
Ships in repo-health. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Find every gap between what the repo expects and what this machine has, before anyone debugs code.
Read only the files that exist. Do not guess a requirement no file states.
| Need | Where it is declared |
|---|---|
| Runtime versions | .tool-versions, .nvmrc, .node-version, package.json engines and packageManager, .python-version, pyproject.toml requires-python, go.mod go, rust-toolchain.toml, .ruby-version, Gemfile, Dockerfile FROM |
| Package manager | lockfile: pnpm-lock.yaml, yarn.lock, package-lock.json, bun.lockb, uv.lock, poetry.lock, Pipfile.lock, Cargo.lock |
| Tools | README / CONTRIBUTING setup steps, Makefile, justfile, Taskfile, package.json scripts, CI workflow setup-* steps (the most reliable list) |
| Env vars | .env.example, .env.sample, .env.template, config schemas (zod/pydantic/envalid), process.env.X / os.environ["X"] / os.Getenv reads |
| Services | docker-compose*.yml, devcontainer.json, DB URLs in .env.example, ports in dev scripts |
Never open .env, .env.local or any secrets file, and never print an env var's value. Check names only: test -n "${NAME+x}", or grep -c '^NAME=' .env to see whether a name is set there without reading it.
Run read-only checks only: <tool> --version, command -v, docker info / docker compose ps, lsof -nP -iTCP:<port> -sTCP:LISTEN, git submodule status, git lfs ls-files | head. Check whether dependencies are installed (node_modules/.modules.yaml, .venv, vendor/) without installing them.
One table, blocking gaps first:
| Check | Repo wants | Machine has | Status | Fix |
|---|---|---|---|---|
| Node | 20.x (.nvmrc) | 18.19.0 | ✗ blocks | nvm install 20 && nvm use |
Status is ✓, ✗ blocks or ⚠ may bite. Each fix is one command, or one sentence when it needs a human (ask a teammate for the secret STRIPE_KEY). End with the order to run the fixes in.
Lessons from earlier runs live in two files: ~/.claude/skill-lessons/env-doctor.md (any repo) and .claude/skill-lessons/env-doctor.md at the repo root (this repo only).
- <YYYY-MM-DD>: <do or avoid X> because <Y>. (seen: 1). When a line already says the same thing, raise its seen count and date instead of adding one. Facts about this repo go in the repo file, everything else in the user file. Keep each file under 30 lines by merging or dropping stale lessons.seen: 3: if the ashish-claude-skills source repo is open, propose the edit to plugins/repo-health/skills/env-doctor/SKILL.md as a diff and wait for a yes, then delete the lesson once it lands; otherwise say Lesson ready to promote: <line> in the report.Learned: <the line written | nothing>.What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
3 skills in this plugin
/api-driftUse when server routes and client calls may have drifted: a 404, 405 or shape error between frontend and backend, after renaming or removing an endpoint, before deleting a route, when an OpenAPI or GraphQL schema changed, or when asked to check API contracts or find dead or unused endpoints. Lists every route and every call, matches them, and reports mismatches with file:line on both sides./flag-cleanupUse when asked to clean up, remove or retire feature flags, find stale or dead flags, or when a flag is fully rolled out or abandoned. Works with any vendor (LaunchDarkly, Unleash, Flagsmith, GrowthBook, PostHog, Statsig, Split, ConfigCat, OpenFeature, Vercel flags) or home-made flags. Inventories every flag, asks which are settled, then removes one flag at a time keeping the winning branch.npx claudepluginhub ashishyd/ashish-claude-skills --plugin repo-health