ワンクリックで
nx-task-guide
Reference for Nx task architecture, orchestration patterns, and how to add or modify build tasks
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Reference for Nx task architecture, orchestration patterns, and how to add or modify build tasks
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Add a new OCLIF command to a CLI package with proper base class, flags, args, and post-creation steps
Create changesets for pending changes by analyzing git diff and commit history
Audit workspace dependencies for version mismatches, unused packages, and sync issues across all packages
Fix all repository policy violations
Run Nx affected commands for the current changes
Reference for OCLIF command patterns, base classes, and conventions used in CLI packages
| name | nx-task-guide |
| description | Reference for Nx task architecture, orchestration patterns, and how to add or modify build tasks |
| user-invocable | false |
This monorepo uses a two-tier task system. Understanding it prevents misconfiguration.
Defined in nx.json targetDefaults. These coordinate work — they have dependsOn but no scripts.
build → depends on: ^build, build:compile, build:api, build:docs, build:manifest, build:readme, build:generate, build:site, build:vitetest → depends on: build:compile, test:unit, test:vitest, test:snapshotscheck → depends on: check:format, check:types, check:deps, check:policy, check:references, check:astro, check:svelteci → depends on: check, build, lint, test:coverage (centralized — update once, all packages inherit)release → depends on: build, release:licensePackages opt in with a minimal entry in package.json:
"nx": { "targets": { "build": {} } }
: prefix)Defined as scripts in each package's package.json. These do the actual work.
Examples: build:compile, build:manifest, test:vitest, check:format
Each has specific inputs and outputs in nx.json for granular caching.
nx.json targetDefaultsaffected over run-many — pnpm nx affected -t build only builds changed packagesproject.json files — all config is centralized in nx.jsonbuild:readme, not build:compile^ prefix means workspace deps first — ^build builds dependencies before the current packageAdd the implementation script to the package's package.json:
"scripts": { "build:custom": "your-command" }
If it should run as part of an orchestration target, add it to nx.json targetDefaults:
"build": { "dependsOn": [..., "build:custom"] }
Add caching config in nx.json if needed:
"build:custom": {
"inputs": ["production", "^production"],
"outputs": ["{projectRoot}/output-dir"]
}
pnpm nx affected -t build # Build changed packages
pnpm nx affected -t test # Test changed packages
pnpm nx run cli:build # Build specific package
pnpm nx run-many -t build # Build ALL packages
pnpm nx affected -t build --dry-run # Preview what would run
pnpm nx reset # Clear cache
pnpm nx graph # Visualize dependency graph
The @nx/vite/plugin auto-creates test:vitest for packages with vitest.config.ts. These work like manually defined tasks but require no configuration.