nx-import

nx-import is a skill for Claude Code from nrwl/nx-ai-agents-config. It costs 0 tokens per session (3,431 once invoked), scanned C, a copy of nx-import, MIT.

Instructions for using Nx import, a command that brings code from another repository or folder into an Nx workspace while preserving its Git history.

In plain words
What is it for?
Importing individual applications or libraries, choosing a destination directory, preserving commits, and handling directory conflicts or version-specific prompts.
Why use it?
They clarify how to import directories without conflicts and explain limits around monorepo folders and root configuration.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the nx plugin — 7 skills, 1 command, 1 agent shipped together

Good fit Importing individual applications or libraries, choosing a destination directory, preserving commits, and handling directory conflicts or version-specific prompts.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/nrwl/nx-ai-agents-config/nx-import
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add nrwl/nx-ai-agents-config --skill nx-import
Clone the repo
git clone --depth 1 https://github.com/nrwl/nx-ai-agents-config

Made for: Claude Code.

Or install nx, the plugin that ships this one along with the rest of its 7 skills, 1 command, 1 agent.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for nx-import

README.md
[![agentmods](https://agentmods.dev/badge/skills/nrwl/nx-ai-agents-config/nx-import/github.svg)](https://agentmods.dev/skills/nrwl/nx-ai-agents-config/nx-import)
Your own site
<a href="https://agentmods.dev/skills/nrwl/nx-ai-agents-config/nx-import"><img src="https://agentmods.dev/badge/skills/nrwl/nx-ai-agents-config/nx-import/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for nx-import

Your own site · 80×15
<a href="https://agentmods.dev/skills/nrwl/nx-ai-agents-config/nx-import"><img src="https://agentmods.dev/badge/skills/nrwl/nx-ai-agents-config/nx-import.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,431 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • Socket pass 18 Mar 2026
  • Snyk pass 13 Mar 2026
How audits are shown
Origin 94% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.03431
Opus 5 $0.00000 $0.01716
Sonnet 5 $0.00000 $0.00686
Haiku 4.5 $0.00000 $0.00343

Measured 11d ago against content hash 541f84c5a39d, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade C, and why

nx-import scanned grade C with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Recursive force deletehighDestructive command

rm -rf with a variable or a broad path is one typo away from removing the wrong tree.

**Fix**: `rm -rf imported/node_modules imported/pnpm-lock.yaml imported/pnpm-workspace.yaml imported/.gitignore`, then `pnpm install`.
Origin

This is a copy

94% identical to nx-import — 5 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

artifacts/skills/nx-import/SKILL.md · 234 lines

How it starts

The opening of the file, as written. The whole thing — 234 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Quick Start

  • nx import brings code from a source repository or folder into the current workspace, preserving commit history.
  • After nx 22.6.0, nx import responds with .ndjson outputs and follow-up questions. For earlier versions, always run with --no-interactive and specify all flags directly.
  • Run nx import --help for available options.
  • Make sure the destination directory is empty before importing. EXAMPLE: target has libs/utils and libs/models; source has libs/ui and libs/data-access — you cannot import libs/ into libs/ directly. Import each source library individually.

Primary docs:

Read the nx docs if you have the tools for it.

Import Strategy

Subdirectory-at-a-time (nx import <source> apps --source=apps):

  • Recommended for monorepo sources — files land at top level, no redundant config
  • Caveats: multiple import commands (separate merge commits each); dest must not have conflicting directories; root configs (deps, plugins, targetDefaults) not imported
  • Directory conflicts: Import into alternate-named dir (e.g. imported-apps/), then rename

Whole repo (nx import <source> imported --source=.):

  • Only for non-monorepo sources (single-project repos)
  • For monorepos, creates messy nested config (imported/nx.json, imported/tsconfig.base.json, etc.)
  • If you must: keep imported tsconfig.base.json (projects extend it), prefix workspace globs and executor paths

Directory Conventions

  • Always prefer the destination's existing conventions. Source uses libs/but dest uses packages/? Import into packages/ (nx import <source> packages/foo --source=libs/foo).
  • If dest has no convention (empty workspace), ask the user.

Application vs Library Detection

Before importing, identify whether the source is an application or a library:

  • Applications: Deployable end products. Common indicators:
    • Frontend: next.config.*, vite.config.* with a build entry point, framework-specific app scaffolding (CRA, Angular CLI app, etc.)
    • Backend (Node.js): Express/Fastify/NestJS server entrypoint, no "exports" field in package.json
    • JVM: Maven pom.xml with <packaging>jar</packaging> or <packaging>war</packaging> and a main class; Gradle application plugin or mainClass setting
    • .NET: .csproj/.fsproj with <OutputType>Exe</OutputType> or <OutputType>WinExe</OutputType>
    • General: Dockerfile, a runnable entrypoint, no public API surface intended for import by other projects
  • Libraries: Reusable packages consumed by other projects. Common indicators: "main"/"exports" in package.json, Maven/Gradle packaging as a library jar, .NET <OutputType>Library</OutputType>, named exports intended for import by other packages.

Read the full file on GitHub · 234 lines

Files

What ships with it

7 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 234 lines · 0 tokens per session scan C 541f84c5a39d

Subscribe to this mod's changes

nx-import is a skill published in the GitHub repository nrwl/nx-ai-agents-config (28 stars, last pushed 1mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 3,431 tokens. A static security scan graded it C with 1 finding (recursive force delete). It is 94% identical to nx-import, differing in 5 lines, and is treated as a copy.

Related

Other skills, from other repositories

prowler-commit

Creates professional git commits following conventional-commits format. Trigger: When creating commits, after completing code changes, when user asks to commit.

prowler-cloud/prowler · 33 tokens

gh-auth-isolation

Safely manage multiple GitHub identities (EMU + personal) in agent workflows.

github/gh-aw · 20 tokens

comet-github

A routing guide for Comet-related GitHub work. It directs requests about pull requests, issues, CI failures, ideas, and fixes to the appropriate review or implementation process.

rpamis/comet · 72 tokens

github-skill

Work with GitHub via the gh CLI — clone repositories, create/list/merge pull requests, create/list issues, and run any other gh command (API calls, workflow runs, releases, repo administration). List operations return parsed JSON.

zeenie-ai/OpenCompany · 51 tokens

changelog-composer

Generates structured changelogs and release notes from git history and PRs, classifying breaking changes, features, fixes, performance, docs. Triggers on: "generate changelog", "write release notes", "what changed since", "prepare release", "release notes for", "diff since tag".

Mathews-Tom/armory · 67 tokens

re0-merge

Review and land an external contribution the way this suite does: gate it against the thesis, land it with the author's credit intact, complete a new skill rather than merging it raw, then approve, credit, and explain before closing. Use when reviewing a pull request, as any collaborator or maintainer, not only the…

LilMGenius/paperthin · 70 tokens