nx-workspace
यह क्या करती है
यह स्किल Nx मोनोरिपो वर्कस्पेस को सेट अप करने और समझने में मदद करती है। यह उन डेवलपर्स और टेक लीड के लिए है जो एक रिपो में कई ऐप और लाइब्रेरी संभालते हैं और तेज़ बिल्ड चाहते हैं।
कब इस्तेमाल करें
- ✓जब आप Nx सेट अप कर रहे हों या समझना चाहते हों कि मोनोरिपो कैसे बना है।
- ✓जब आप प्रोजेक्ट सीमाएँ तय करना चाहते हों या देखना चाहते हों कि कौन-से प्रोजेक्ट एक-दूसरे पर निर्भर हैं।
- ✓जब आप प्रभावित कमांड और बिल्ड कैशिंग से CI को तेज़ करना चाहते हों।
Skill का लिंक
https://github.com/tech-leads-club/agent-skills/blob/main/packages/skills-catalog/skills/(tooling)/nx-workspace/SKILL.mdइसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।
कैसे इस्तेमाल करें
सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।
पेस्ट करने के लिए तैयार मैसेज
Claude Code, Codex या Cursor के लिए: प्रोजेक्ट फ़ोल्डर में चलाएँ और skill इंस्टॉल हो जाएगी।
SKILL.md डाउनलोड करें और अपने एजेंट के skills फ़ोल्डर में रखें।
AI से क्या माँगें: उदाहरण
“क्या आप समझा सकते हैं कि मेरा Nx वर्कस्पेस कैसे व्यवस्थित है, और हमारे CI बिल्ड को तेज़ करने के तरीके सुझा सकते हैं?”
हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।
यह कैसे काम करती है
एजेंट प्रोजेक्ट्स की सूची बनाता है, Nx कमांड से उनकी पूरी हल की गई कॉन्फ़िगरेशन पढ़ता है, और संरचना का नक्शा बनाता है। फिर वह तेज़ पाइपलाइन के लिए सीमाओं, कैशिंग और प्रभावित कमांड में बदलाव सुझाता है।
तकनीकी सामग्री (मूल SKILL.md)
लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।
Nx Workspace Management
Quick Start
Exploring workspace: nx show projects and nx show project <name> --json
Running tasks: nx <target> <project> (e.g., nx build my-app)
Affected analysis: nx show projects --affected or nx affected -t <target>
Note: Prefix commands with
npx/pnpx/yarnif nx isn't installed globally.
Core Commands
List and Explore Projects
# List all projects
nx show projects
# Filter by type, pattern, or target
nx show projects --type app
nx show projects --projects "apps/*"
nx show projects --withTarget build
# Find affected projects
nx show projects --affected --base=main
Get Project Information
Critical: Always use nx show project <name> --json for full resolved configuration. Do NOT read project.json directly - it contains only partial configuration.
# Get full configuration
nx show project my-app --json
# Extract targets
nx show project my-app --json | jq '.targets | keys'
Configuration schemas:
- Workspace:
node_modules/nx/schemas/nx-schema.json - Project:
node_modules/nx/schemas/project-schema.json
Run Tasks
# Run specific project
nx build web --configuration=production
# Run affected
nx affected -t test --base=main
# View dependency graph
nx graph
Workspace Architecture
workspace/
├── apps/ # Deployable applications
├── libs/ # Shared libraries
│ ├── shared/ # Shared across scopes
│ └── feature/ # Feature-specific
├── nx.json # Workspace configuration
└── tools/ # Custom executors/generators
Library Types
| Type | Purpose | Example |
|---|---|---|
| feature | Business logic, smart components | feature-auth |
| ui | Presentational components | ui-buttons |
| data-access | API calls, state management | data-access-users |
| util | Pure functions, helpers | util-formatting |
Detailed Resources
Configuration: See reference/configuration.md for:
- nx.json templates and options
- project.json structure
- Module boundary rules
- Remote caching setup
Commands: See reference/commands.md for:
- Complete command reference
- Advanced filtering options
- Common workflows
CI/CD: See reference/ci-cd.md for:
- GitHub Actions configuration
- GitLab CI setup
- Jenkins, Azure Pipelines, CircleCI examples
- Affected commands in pipelines
Best Practices: See reference/best-practices.md for:
- Do's and don'ts
- Complete troubleshooting guide
- Performance optimization
- Migration guides
Common Workflows
"What's in this workspace?"
nx show projects --type app # List applications
nx show projects --type lib # List libraries
"How do I run project X?"
nx show project X --json | jq '.targets | keys'
"What changed?"
nx show projects --affected --base=main
Quick Troubleshooting
- Targets not showing: Use
nx show project <name> --json, not project.json - Affected not working: Ensure git history available (
fetch-depth: 0in CI) - Cache issues: Run
nx reset
For detailed troubleshooting, see reference/best-practices.md.
अक्सर पूछे जाने वाले सवाल
project.json सीधे क्यों न पढ़ें?
स्किल कहती है कि project.json में केवल आंशिक सेटिंग्स होती हैं, इसलिए पूरी कॉन्फ़िगरेशन Nx से मिलती है।
क्या यह डिपेंडेंसी ग्राफ़ दिखा सकती है?
हाँ। यह Nx कमांड से प्रोजेक्ट डिपेंडेंसी ग्राफ़ दिखा सकती है।
क्या यह टास्क भी चलाती है?
टास्क चलाना एक अलग स्किल का काम है, लेकिन जब आप कहें तो यह कोई टारगेट चला सकती है।
जानकारी
लेखक का मूल विवरण
Configure, explore, and optimize Nx monorepo workspaces. Use when setting up Nx, exploring workspace structure, configuring project boundaries, analyzing affected projects, optimizing build caching, or implementing CI/CD with affected commands. Keywords — nx, monorepo, workspace, projects, targets, affected. Do NOT use for running tasks (use nx-run-tasks) or code generation with generators (use nx-generate).
लोकप्रियता
- GitHub स्टार
- 7.1k
- रैंकिंग में स्थान
- #13574
- लाइसेंस
- —
- अपडेट की गई
- 2/11/2026
कमेंट
- …
इस repository की और skills
component-common-domain-detection
7.1kयह आपके एजेंट को कोडबेस के कई हिस्सों में दोहराए गए बिज़नेस लॉजिक को ढूँढने और उन्हें मिलाने का तरीका सुझाने में मदद करती है।
component-flattening-analysis
7.1kयह आपके एजेंट को गलत जगह रखा गया कोड ढूँढने और उलझे हुए कंपोनेंट फ़ोल्डर ढाँचे को सीधा करने में मदद करती है, ताकि हर चीज़ अपनी सही जगह रहे।
component-identification-sizing
7.1kयह आपके एजेंट को कोडबेस के हिस्सों का नक्शा बनाने और उनका आकार मापने में मदद करती है, ताकि पता चले कि पहले किस मॉड्यूल को तोड़ना है।
coupling-analysis
7.1kयह आपके एजेंट को जाँचने में मदद करती है कि कोडबेस के हिस्से एक-दूसरे पर कितनी कसकर निर्भर हैं, और पहले कौन से जोड़ ढीले करने चाहिए।
मिलती-जुलती skills
openclaw-update
394kयह आपके एजेंट को चल रहे OpenClaw Gateway को अपडेट करने में मदद करती है, इंस्टॉल के तरीके के अनुसार सही विधि चुनकर और सेशन बनाए रखकर।
diagnose-gateway
394kयह आपके एजेंट को सेटिंग्स, चैनल और पोर्ट जांचकर पता लगाने देती है कि OpenClaw Gateway क्यों फ़ेल हो रहा है, बिना कुछ बदले।
crabbox-apps
394kयह आपके एजेंट को किसी अस्थायी क्लाउड मशीन पर ऐप खोलने और चलाने देती है, फिर उसका व्यू आपके चैट के साइड पैनल में दिखाती है।