npm-workspaces
Use when managing npm workspaces monorepos - package dependencies, build ordering, cross-package development, and publishing workflows
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Use when managing npm workspaces monorepos - package dependencies, build ordering, cross-package development, and publishing workflows
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Use when writing or editing .omg.md files - the human-first DSL for API specification that compiles to OpenAPI 3.1
Use when building CLI tools with Commander.js - commands, options, arguments, and help text for Node.js command-line applications
Use when parsing or generating Markdown following the CommonMark specification - AST structure, block/inline elements, and extensions
Use when creating GitHub Actions workflows for CI/CD - testing, building, publishing npm packages, and automating repository tasks
Use when working with JSON Schema for validation, OpenAPI schemas, type definitions, and data structure specification
Use when implementing Language Server Protocol features - diagnostics, completions, hover, go-to-definition, and editor integration
| name | npm-workspaces |
| description | Use when managing npm workspaces monorepos - package dependencies, build ordering, cross-package development, and publishing workflows |
// Root package.json
{
"name": "my-monorepo",
"private": true,
"workspaces": ["packages/*"],
"scripts": {
"build": "npm run build --workspaces",
"test": "npm run test --workspaces"
}
}
| Command | Purpose |
|---|---|
npm install | Install all workspace deps |
npm run build --workspaces | Run in all workspaces |
npm run build -w pkg-name | Run in specific workspace |
npm run build --if-present | Skip if script missing |
// packages/compiler/package.json
{
"name": "my-compiler",
"dependencies": {
"my-parser": "^1.0.0" // Reference sibling package
}
}
file:) for publishable packages// Root package.json - explicit order
{
"scripts": {
"build": "npm run build -w my-parser && npm run build -w my-compiler && npm run build -w my-cli"
}
}
Or use a tool like wireit or turbo for dependency-aware builds.
# Update versions (from root)
npm version patch -w my-parser
npm version patch -w my-compiler
# Publish all
npm publish --workspaces
# Publish specific
npm publish -w my-parser
"private": true in root to prevent accidental publishnpm ls to verify dependency resolutionnpm explain <pkg> to debug why a package is installedengines field to enforce Node version--include-workspace-root to also run in root