--- name: fix-repository-diagnostics description: Verify or fix diagnostic findings in JavaScript/TypeScript repositories using project tooling. Use for project-wide checks or a scoped repair batch. disable-model-invocation: true --- # Fix Repository Diagnostics Run a closed diagnostic loop: discover tooling, collect the baseline, verify findings and select the repair batch, fix root causes, and rerun diagnostics before reporting. Follow explicit user instructions when they override this skill's defaults. For fix requests, carry the selected batch through verification and reporting without pausing for routine allocation or implementation choices. Continue independent authorized work when a finding is blocked or requires approval. ## 1. Discover Repository Tooling 1. Work from the repository root and read the applicable repository instructions. 2. Inspect the worktree before editing. Preserve user-owned changes and identify files already modified by others. 3. Inspect package scripts, their wrappers, workspace configuration, and diagnostic configuration files to identify the project's lint, typecheck, and other configured diagnostic commands. Use installed dependencies as supporting evidence; a package's presence alone does not establish that the repository uses it for diagnostics. 4. Prefer repository-defined commands and preserve their configuration and wrapper behavior. Use `bun run