turborepo

Configure Turborepo task pipelines, caching, and filtering for JavaScript monorepos.

Updated May 28, 2026
One-click install
npx skills add https://github.com/mrisoli/pokerhouse --skill turborepo-mrisoli
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: turborepo
Source: https://github.com/mrisoli/pokerhouse/tree/main/.agents/skills/turborepo
Command: npx skills add https://github.com/mrisoli/pokerhouse --skill turborepo-mrisoli

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Setting up and maintaining a Turborepo monorepo involves many subtle configuration decisions—task dependencies, cache inputs, environment variables, and CI integration—where small mistakes silently break caching or parallelization. This Skill provides decision trees, anti-pattern detection, and reference documentation to configure turbo.json correctly the first time. ## Core Features & Use Cases - Task Pipeline Configuration: Guides creation of package tasks over root tasks, correct dependsOn syntax (^build vs build), outputs declaration, and transit nodes for parallel tasks with cache invalidation. - Cache Debugging & Optimization: Diagnoses cache misses, configures remote caching, and handles environment variable hashing with env, globalEnv, and passThroughEnv keys. - Filtering & CI Setup: Covers --affected and --filter syntax for running only changed packages, plus GitHub Actions and Vercel deployment patterns with turbo-ignore. - Use Case: Your CI builds every package on every pull request. Use this Skill to switch to turbo run build --affected with remote caching so only changed packages and their dependents rebuild. ## Quick Start Ask the assistant to review your turbo.json and package.json scripts for Turborepo anti-patterns and fix any caching or task configuration issues.

Frequently Asked Questions about turborepo

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I run only changed packages in Turborepo?▼

Use the --affected flag: turbo run build --affected compares your branch against the default branch and runs tasks only in changed packages and their dependents. You can customize the base with --affected-base=origin/develop.

How do I configure task dependencies in turbo.json?▼

Use dependsOn with the caret syntax: "build": { "dependsOn": ["^build"] } runs build in dependency packages first. Without the caret, it refers to the same package's task. Declare scripts in each package's package.json and register tasks in root turbo.json.

Why is my Turborepo cache not working?▼

Common causes include missing outputs keys for file-producing tasks, environment variables not listed in the env key, or .env files absent from inputs. Debug with --summarize or --dry to inspect hash inputs, and check that lockfiles are committed.

Should I use turbo or turbo run in package.json scripts?▼

Always use turbo run in package.json scripts, CI workflows, and any committed code. The turbo <task> shorthand is intended only for one-off terminal commands typed directly by humans.

Does Turborepo support environment variables in caching?▼

Yes. List variables in a task's env key so changes invalidate that task's cache, or use globalEnv for variables affecting all tasks. Use passThroughEnv for runtime-only variables like credentials that should not affect cache keys.

When should I use Root Tasks instead of package tasks?▼

Only when a task truly cannot exist in a package, such as repo-wide release scripts or Vitest Projects' //#test. Package tasks enable parallelization, individual caching, and filtering, so they should be the default for build, lint, and test.