project-references-migration
Use when a layered TypeScript workspace needs an incremental project-references migration without breaking package boundaries or editor resolution.
Skill by matt-riley
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/matt-riley-project-references-migration
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md and code. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/project-references-migration
What's inside
- Skill name
project-references-migration- Description
- Use when a layered TypeScript workspace needs an incremental project-references migration without breaking package boundaries or editor resolution.
- License
- GPL-3.0
- Metadata
- kind: task · version: 1.0.0 · audience: general-coding-agent · category: typescript · maturity: draft
- Instructions
- 143 lines in SKILL.md · view on GitHub
Files (2)
- SKILL.md
- migration-checklist.md · references/
SKILL.md (first lines)
# Project references migration
## Use this skill when
- The repository has multiple TypeScript packages or layers and needs faster, more reliable builds.
- The user wants to adopt `tsc -b` project references incrementally.
- Declaration output, package boundaries, or editor performance are suffering in a growing TypeScript workspace.
- You need to make the graph coherent enough for `tsc -b`, fresh declarations, and editor go-to-definition to agree.
## Do not use this skill when
- The repository is a small single-project TypeScript setup.
- The task is only to fix one package's local `tsconfig`.
- The workspace already has healthy project references and only needs routine maintenance.
- The main goal is strictness hardening or general `tsconfig` cleanup rather than adopting `composite`, `references`, or `tsc -b`.
## Inputs to gather
**Required before editing**
- The package or layer graph and their current `tsconfig` files.
- The existing build and typecheck commands.
- Whether each package emits declarations, JavaScript, or types only.
- Output directories, package exports, and path alias usage.
**Helpful if present**
- Existing workspace tooling such as Nx, Turborepo, pnpm workspaces, or custom scripts.
- Known circular dependencies.
- Editor or CI pain points that motivate the migration.
## First move
1. Inventory the package graph, current `tsconfig` chain, and any obvious cycles.
2. Pick one leaf or low-risk package as the pilot migration surface.
3. Confirm how declarations, outputs, and package boundaries work today before adding references.
4. Stop and split the boundary if a proposed reference would create a cycle.
## Common shapes
Solution config:
```json
{
"files": [],
"references": [
{ "path": "./packages/core" },
{ "path": "./packages/ui" }
]
}
```
Pilot package config:
```json
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"composite": true,
"declaration": true,
"declarationMap": true,
"rootDir": "src",
"outDir": "dist"
},
"references": [{ "path": "../core" }]
}
```
## Workflow
1. Create or normalize a shared base config only for settings that truly belong across referenced packages.
2. Enable `composite` and the required declaration settings on the pilot package.
3. Add explicit `references` only where the dependency graph is already real.
4. Align output directories, package exports, and path aliases with the referenced build layout.
5. Migrate packages incrementally from leaves upward.
6. Switch scripts to `tsc -b` or the repository's equivalent only after the referenced graph is coherent.
7. If a cycle appears, stop widening and split the dependency before adding more references.
## Outputs
- tsconfig and import changes that enable project references without breaking editor or build resolution for the workspace.
- Evidence (build, type-check, or test) that the migration is safe.
## Guardrails
- **Must not** migrate the whole workspace in one leap without a proven pilot.
- **Must not** introduce circular references to mirror accidental runtime coupling.
- **Should** keep runtime resolution, package exports, and declaration output aligned.
- **Should** prefer real package boundaries over giant shared path-alias surfaces.
- **May** leave exceptional packages on local configs temporarily when the graph is not ready.
- **Should** treat a repeated cycle or stale output mismatch as a sign to pause migration, not to add another config layer.
## Troubleshooting
- If the build succeeds but the editor opens stale declarations, restart the TypeScript server or reopen the workspace after confirming the package graph changed.
- If go-to-definition lands in the wrong emitted folder, verify `rootDir`, `outDir`, `declaration`, and package exports point at the same build layout.
- If outputs land beside source or in an unexpected subdirectory, inspect the package's `tsconfig` inheritance before widening the reference graph.
## Routing boundary
- Use this skill when a multi-package TypeScript workspace needs a deliberate `composite` / `references` migration path.
- Route to [`tsconfig-hardening`](../tsconfig-hardening/SKILL.md) when the task is mainly single-package compiler-option cleanup or strictness tuning.
- Route to [`tsc-error-triage`](../tsc-error-triage/SKILL.md) when the references migration has already landed and remaining work is source-level compiler failure triage.
## Validation
- Run the repository's referenced build or the nearest equivalent after each migration batch.
- Confirm declarations and outputs land in the expected locations.
- Run the typecheck workflow that consumes cross-package imports, not just the referenced build.
- Open a consuming file in the editor when possible, trigger go-to-definition on an imported symbol, and confirm it resolves to the expected referenced package source or fresh declarations rather than stale outputs.
- Smoke test:
- should trigger: "Add tsconfig references across our TS packages so tsc -b works."
- should not trigger: "Enable noUncheckedIndexedAccess in one package safely." (→ `tsconfig-hardening`)
## Examples
- `Before`
```jsoncFrom matt-riley/agent-skills, GPL-3.0.
More from matt-riley/agent-skills
- 0.614score
code-intelligence
matt-riley
Use when navigating or refactoring code — choosing between LSP, rg, or semantic search tools; an LSP call returns empty and you need to know if it failed; or…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
code-tour
matt-riley
Use when asked to create a .tour walkthrough — onboarding, PR review, RCA, architecture, or any persona-targeted step-by-step code narrative.
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
agent-governance
matt-riley
Use this skill when building AI agents that call external tools, implementing policy-based access controls, adding semantic intent classification, creating…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
agentic-eval
matt-riley
Use when designing or implementing an evaluation loop for AI agent outputs — reflection loops, evaluator-optimizer pipelines, LLM-as-judge scoring, or…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
api-smoke-validation
matt-riley
Use when running quick, repeatable API smoke tests after changes with hurl, including auth, status-code, response-shape, endpoint sanity, and pre-integration…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
aws-sdk-v2-to-v3-migration
matt-riley
Use when the codebase still imports from 'aws-sdk' v2, uses new AWS.*() constructors, .promise() calls, AWS.config.update(), DocumentClient, or s3.upload() —…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
circleci-to-github-actions-migration
matt-riley
Use when a repository still depends on .circleci/config.yml jobs, workflows, or artifacts that need to be replaced or phased out with GitHub Actions —…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
mocha-to-jest-migration
matt-riley
Use when a JavaScript or TypeScript suite still depends on Mocha, Chai, or Sinon and needs an incremental Jest migration.
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
ast-grep
matt-riley
Use when you need ast-grep structural search, linting, or safe codemod rewrites, especially for requests that mention ast-grep, sg, codemod, rule files, or…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
agent-instructions
matt-riley
Use when creating or updating agent instruction files (AGENTS.md for Pi, copilot-instructions.md for Copilot, per-path guides, or AGENTS.md router) —…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
autoresearch
matt-riley
Use when running autonomous iterative experiments to optimize a measurable metric on an existing codebase — not for writing tests or diagnosing a specific…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
aws-lambda-go-deployment
matt-riley
Use when deploying or debugging Go-based AWS Lambda packaging, bootstrap, runtime, or handler issues — not when the main failure is SAM stack wiring, IAM OIDC…
SkillAFreshness: A★ 4Claude Code +9
Signals
- Stars
- 4
- Forks
- 0
- Open issues
- 1
- Last commit (this folder)
- Jun 28, 2026 (4 months ago)
- Last release
- Oct 23, 2026 (5 days ago)
From GitHub (fetched Oct 24, 2026).
Details
- Version
- 1.0.0
- License
- GPL-3.0
- Repository
- github.com/matt-riley/agent-skills
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from matt-riley
- 0.614score
agent-instructions
matt-riley
Use when creating or updating agent instruction files (AGENTS.md for Pi, copilot-instructions.md for Copilot, per-path guides, or AGENTS.md router) —…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
agent-supply-chain
matt-riley
Use this skill when generating SHA-256 integrity manifests for agent plugins, verifying that installed plugins match their manifests, detecting tampered…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
agentic-eval
matt-riley
Use when designing or implementing an evaluation loop for AI agent outputs — reflection loops, evaluator-optimizer pipelines, LLM-as-judge scoring, or…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
api-smoke-validation
matt-riley
Use when running quick, repeatable API smoke tests after changes with hurl, including auth, status-code, response-shape, endpoint sanity, and pre-integration…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
aws-sdk-v2-to-v3-migration
matt-riley
Use when the codebase still imports from 'aws-sdk' v2, uses new AWS.*() constructors, .promise() calls, AWS.config.update(), DocumentClient, or s3.upload() —…
SkillAFreshness: A★ 4Claude Code +9 - 0.614score
agent-governance
matt-riley
Use this skill when building AI agents that call external tools, implementing policy-based access controls, adding semantic intent classification, creating…
SkillAFreshness: A★ 4Claude Code +9
Cite this page
project-references-migration skill. Agent Mart. https://agentmart.dev/skills/matt-riley-project-references-migration (last updated 2026-10-24)