# compare-cache-runs

compare-cache-runs is a Claude Code skill that compares two Tuist cache runs, revealing hit-rate changes, root causes, and cascade effects through dependencies.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode, Windsurf (Devin Desktop), Claude.ai · 291 installs · ★ 35 repo stars
- Author: tuist
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/tuist/agent-skills/tree/HEAD/skills/compare-cache-runs/SKILL.md
- Updated: 2026-03-27
- Security check: automated, 2026-11-16 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/skills/compare-cache-runs

## What it does

The skill takes two cache run identifiers (run ID, dashboard URL, or branch name), fetches metrics via `tuist cache-run list` and `tuist cache-run show`, and compares execution time, local and remote cache hits, and cacheable target counts.

When cache hit rate drops, the skill examines `git diff` to find which files changed, maps them to Tuist modules, and flags modules with direct source changes as root causes. It then calculates cascade impact: if module B depends on module A and A is invalidated, B loses cache too even though its source didn't change.

Output includes a verdict (cache improved, regressed, or stable), hit-rate delta, root cause targets, cascade breadth, and actionable recommendations like splitting large modules, using interface patterns, or pre-warming caches before merge.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add tuist/agent-skills --skill compare-cache-runs -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/compare-cache-runs/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/compare-cache-runs/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add tuist/agent-skills --skill compare-cache-runs -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/compare-cache-runs/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add tuist/agent-skills --skill compare-cache-runs -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/compare-cache-runs/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install tuist/agent-skills skills/compare-cache-runs
```

2. **Manually: put the files in place**
- File: `.github/skills/compare-cache-runs/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add tuist/agent-skills --skill compare-cache-runs -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/tuist/agent-skills --path skills/compare-cache-runs
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/compare-cache-runs/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add tuist/agent-skills --skill compare-cache-runs -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/tuist/agent-skills/tree/HEAD/skills/compare-cache-runs/SKILL.md

## When to use it
- compare cache hit rates between two project versions
- identify which module broke cache for downstream targets
- measure build-time impact of changes through cache metrics
- distinguish expected cache misses from unexpected ones
- get recommendations to reduce cache invalidation

## Example prompts
- Compare cache between main and my current feature branch
- Show me why run-123 and run-456 have different hit rates
- Analyze cache invalidation cascade from commits abc1234 to def5678

## Similar
- [magento-cache-analyst](https://affpapa.org/en/nevibecode/skills/magento-cache-analyst.md) — skill · 160 installs
- [nx-cloud-cache-investigator](https://affpapa.org/en/nevibecode/skills/nx-cloud-cache-investigator.md) — skill · 127 installs
- [cleanup-cache](https://affpapa.org/en/nevibecode/commands/cleanup-cache.md) — command · 416 installs
- [runtime-cache](https://affpapa.org/en/nevibecode/skills/runtime-cache.md) — skill · 6 installs
- [nextjs-cache-handler-mcp](https://affpapa.org/en/nevibecode/mcp/nextjs-cache-handler-mcp.md) — MCP server · ★ 6 repo stars
- [cache-stats](https://affpapa.org/en/nevibecode/plugins/cache-stats.md) — plugin

From the same set: [tuist/agent-skills](https://affpapa.org/en/nevibecode/by/tuist/agent-skills.md) — 12 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
