checkmate-refresh
/checkmate-refresh
Sync checkmate.json with currently installed tools. Use when linters or formatters have been added, removed, or updated.
- Author
- rcrsr ↗
- Repository
- checkmate ↗
- Licence
- MIT
- Last repository change
- 01.10.2026
Assessment and security
- Files in this package
- 1
- Scripts
- 0
- HTML comments
- 0
- URLs in SKILL.md
- 0
No signals detected. Repository changed on 01.10.2026, without references to retired models or APIs.
MIT, open: use and modify while retaining author attribution.
What it does and when to use it
Sync checkmate.json with currently installed tools. Use when linters or formatters have been added, removed, or updated.
Original author description
Sync checkmate.json with currently installed tools. Use when linters or formatters have been added, removed, or updated.
How it works
- Instructions
- Notes
SKILL.md preview
---
name: checkmate-refresh
description: Sync checkmate.json with currently installed tools. Use when linters or formatters have been added, removed, or updated.
disable-model-invocation: true
user-invocable: true
argument-hint: ""
---
# checkmate-refresh
Maintain and update the existing `.claude/checkmate.json` configuration.
## Instructions
You are helping maintain an existing checkmate configuration. This command:
1. Validates current config against installed tools
2. Detects newly installed tools
3. Identifies removed or broken tools
4. Suggests config updates
### Step 1: Load Current Config
Read the existing configuration:
```bash
cat .claude/checkmate.json
```
**If file not found, STOP and warn the user:**
```
No checkmate configuration found at .claude/checkmate.json
The /checkmate:checkmate-refresh command updates an existing configuration.
To create a new configuration, run /checkmate:checkmate-init instead.
```
Do not proceed if no config exists. Direct user to `/checkmate:checkmate-init`.
### Step 2: Detect Current Package Managers
Use the `checkmate:detect-environment` subagent to detect current package managers and invocation patterns.
Compare against config - if package manager changed (e.g., switched from npm to pnpm), suggest updating all tool commands.
### Step 3: Validate Configured Tools
For each check in the config, verify the command exists using the detected exec pattern:
```bash
<exec> <tool> --version 2>/dev/null && echo "<tool> OK" || echo "<tool> MISSING"
```
For npm environments, do not append the tool name to a generic exec prefix. Probe the resolved bin path from the detect agent's `bins` map instead:
```bash
node <bins.tool> --version 2>/dev/null && echo "<tool> OK" || echo "<tool> MISSING"
```
Report:
- Tools that are configured but missing
- Tools with version changes (if version flags available)
- Tools using wrong invocation pattern:
- Any `npx` usage: `npx` re-resolves the package on every run and can fetch from the npm registry mid-hook. Re-run `checkmate:detect-environment` and replace the check with the resolved bin path from its `bins` map (`{ "command": "node", "args": ["node_modules/<pkg>/<bin-path>", ...] }`).
- Manager mismatch (e.g. `pnpm exec` configured in a project that now uses npm): update to the currently detected manager's exec pattern.
- Stale bin paths: a configured `node_modules/<pkg>/<bin-path>` that no longer exists (package removed, or bin path moved after an upgrade). Re-resolve the path via `checkmate:detect-environment`, or if the package is gone, recommend reinstalling it via the detected manager (`pnpm add -D` / `yarn add -D` / `npm i -D` / `bun add -d`).
- `ruff check` without `--output-format=concise`: ruff 0.15 changed the default output to a multi-line format the `ruff` parser cannot match, degrading diagnostics to a raw text dump. Add `--output-format=concise` before `$FILE`.
- `oxlint` without `--format=unix --deny-warnings`: without `--format=unix` the output does not match the `oxlint` parser, and without `--deny-warnings` warning-level findings exit 0 and are never reported. Add both flags, and set `"parser": "oxlint"` if the check still uses `generic`.
- `oxfmt` checks using the `generic` parser: switch to `"parser": "prettier"` (boolean pass/fail) so failures report as a clean "File needs formatting" instead of a raw text dump.
### Step 4: Discover New Tools
Using the detected invocation pattern, check for tools that aren't in the config:
**JavaScript/TypeScript** (using detected exec pattern):
```bash
<exec> prettier --version 2>/dev/null && echo "prettier available"
<exec> eslint --version 2>/dev/null && echo "eslint available"
<exec> biome --version 2>/dev/null && echo "biome available"
<exec> oxlint --version 2>/dev/null && echo "oxlint available"
<exec> oxfmt --version 2>/dev/null && echo "oxfmt available"
<exec> tsc-files --version 2>/dev/null && echo "tsc-files available"
```
**Note:** Avoid `tsc` - it checks the entire project on every file change. Use `tsc-files` (per-file) or `eslint` with `@typescript-eslint` instead.
**Python** (using detected exec pattern):
```bash
<exec> ruff --version 2>/dev/null && echo "ruff available"
<exec> ty --version 2>/dev/null && echo "ty available"
<exec> mypy --version 2>/dev/null && echo "mypy available"
```
**Go:**
```bash
command -v golangci-lint && golangci-lint --version
command -v staticcheck && staticcheck --version
```
**C/C++:**
```bash
command -v clang-format && clang-format --version
command -v clang-tidy && clang-tidy --version
command -v cppcheck && cppcheck --version
# macOS Homebrew LLVM (not in PATH)
/opt/homebrew/opt/llvm/bin/clang-format --version 2>/dev/null
```
**Shell:**
```bash
command -v shellcheck && shellcheck --version
command -v shfmt && shfmt --version
```
Compare against config - identify tools present but not configured.
### Step 5: Check for File Type Coverage
Find file types in the project:
```bash
# Code files
find . -type f \( -name "*.py" -o -name "*.ts" -o -name "*.tsx" -o -name "*.js" -o -name "*.go" -o -name "*.rs" -o -name "*.cpp" -o -name "*.c" -o -name "*.h" -o -name "*.hpp" -o -name "*.sh" \) | \
sed 's/.*\./\./' | sort | uniq -c | sort -rn
# Formatter-compatible files
find . -type f \( -name "*.json" -o -name "*.md" -o -name "*.yaml" -o -name "*.yml" -o -name "*.css" \) | \
sed 's/.*\./\./' | sort | uniq -c | sort -rn
```
Report file types that exist but have no checks configured. Include formatter-compatible files if prettier or biome is available.
### Step 6: Present Findings
Show the user a summary:
**Status Report:**
- Configured tools: X working, Y missing
- New tools detected: [list]
- Uncovered file types: [list]
**Suggested changes:**
- Remove checks for missing tools: [list]
- Add checks for new tools: [list with proposed config]
- Add coverage for file types: [list]
**Related file types:** If prettier or biome is configured, suggest extending to:
- `.json` - package.json, tsconfig.json, config files
- `.md` - README, documentation
- `.yaml,.yml` - CI configs, docker-compose
- `.css,.scss` - stylesheets (if present in project)
### Step 7: Apply Updates
After user confirmation:
**Critical: Only modify checks with `_auto: true`**
The `_auto` field marks checks that were auto-discovered by `/checkmate:checkmate-init`. Checks without this marker are user-added and must never be modified or removed.
1. **Remove broken auto checks:** Delete entries with `_auto: true` for tools that are no longer installed
2. **Add new tools:** Append new check configurations with `_auto: true` (use the `checkmate:configure-tool` subagent for unfamiliar tools)
3. **Update auto checks:** Modify invocation patterns only for checks with `_auto: true`
4. **Never touch user checks:** Checks without `_auto` marker are always preserved exactly as-is
Write the updated config:
```bash
# Backup first
cp .claude/checkmate.json .claude/checkmate.json.bak
```
Then write the new configuration.
### Step 8: Review Changes
**Always ask the user to review changes before finishing:**
Show a structured diff that distinguishes auto vs user checks:
```
Config Changes Summary
PRESERVED (user checks, no _auto marker):
✓ .py: custom-linter (user-added, never modified)
✓ .go: project-specific-check (user-added, never modified)
AUTO CHECKS - PROPOSED CHANGES:
+ Add: prettier for .ts,.tsx (_auto: true)
+ Add: eslint for .ts,.tsx (_auto: true)
- Remove: old-linter for .py (tool not found, was _auto: true)
~ Update: ruff invocation npm→pnpm (_auto: true)
NO CHANGES:
= .py: ruff (auto, still valid)
Confirm to apply, or specify changes.
```
Ask:
- Are the suggested additions correct?
- Are the removed checks intentional (tools uninstalled)?
- Are invocation patterns still correct after any package manager changes?
### Step 9: Test Updated Config
After user confirms, test with a sample file:
```bash
# Find a file that matches configured extensions
find . -name "*.py" -o -name "*.ts" | head -1
```
Run one of the updated commands manually to verify it works.
Report success or any issues found.
## Notes
- Always backup before modifying config
- **Only modify checks with `_auto: true`** - user checks (no marker) are never touched
- If a tool moved (e.g., from global to project-local), update the command path for `_auto` checks only
- For tools with major version upgrades, output format may have changed - suggest re-running configure-tool
- Users can remove `_auto: true` from any check to "claim" it and prevent future modifications
Versions
The database has no other skills named checkmate-refresh.
Database snapshot: 13.11.2026 · package version d148930a0a9d (SHA-256 digest of the entire package)
Downloads in the last 30 days: 0 · ranking
Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.
Similar skills
- 95checkmate-init
Auto-discover linting and formatting tools, generate .claude/checkmate.json configuration. Use when setting up checkmate for a new project. - 90checkmate
Goal-driven mode for AI coding agents. Activates when the user says "/checkmate", "checkmate mode", "be goal driven", "shortest path", "fewest tokens", "fewest moves", or "mate in the fewest moves". Makes the agent identify the win condition and take the shortest path to it. - 100code-style
Guide for running code style linters and formatters. Use this when asked to check code style, run linters, or fix formatting issues. - 80Global Coding Style
Maintain consistent code formatting, naming conventions, and structure across the entire codebase with automated tools and clear standards. Use this skill when writing any code in any language or framework. When naming variables, functions, classes, or files. When formatting…