Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
nrwl avatar

Nx Run Tasks

  • 2.5k installs
  • 27 repo stars
  • Updated July 23, 2026
  • nrwl/nx-ai-agents-config

nx-run-tasks explains nx run, run-many, and affected commands with discovery and CI-oriented flags.

About

The nx-run-tasks skill documents how agents run Nx tasks in monorepos. Prefix commands with npx, pnpx, or yarn when Nx is not global, determined from package.json or lockfiles. Discover runnable targets via nx show project PROJECT --json targets section, which includes plugin-inferred tasks beyond package.json scripts. Single tasks use nx run project:task where project comes from package.json or project.json names. Multiple tasks use nx run-many -t build test lint with optional -p project filters, --exclude, and --parallel controlling concurrency defaulting to three. Examples cover pattern filters like *-app, tag selectors tag:api-*, and explicit project lists. Affected runs limit work to changed projects and dependents via nx affected -t build test lint, comparing against base branches with --base and --head or direct --files paths for CI efficiency. Shared flags across run, run-many, and affected include --skipNxCache, --verbose, --nxBail, and --configuration for named configs like production. Help text is available per command with --help.

  • Prefix with npx, pnpx, or yarn when nx is not installed globally.
  • nx show project NAME --json lists targets including inferred plugin tasks.
  • nx run project:task for one target; run-many -t for multiple projects.
  • nx affected runs only changed projects and dependents for CI.
  • Flags: --skipNxCache, --verbose, --nxBail, --configuration, --parallel.

Nx Run Tasks by the numbers

  • 2,479 all-time installs (skills.sh)
  • +72 installs in the week ending Aug 5, 2026 (Skillselion tracking)
  • Ranked #76 of 1,435 DevOps & CI/CD skills by installs in the Skillselion catalog
  • Security screen: MEDIUM risk (skills.sh audit)
  • Data as of Aug 5, 2026 (Skillselion catalog sync)
At a glance

nx-run-tasks capabilities & compatibility

Capabilities
project target discovery via nx show project · single and multi project task execution · affected graph runs for ci efficiency · cache, bail, verbose, and configuration flags
Use cases
ci cd · devops · testing
Platforms
macOS · Linux · Windows · WSL
Runs
Runs locally
Pricing
Free
From the docs

What nx-run-tasks says it does

nx run <project>:<task>
SKILL.md
npx skills add https://github.com/nrwl/nx-ai-agents-config --skill nx-run-tasks

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs2.5k
repo stars27
Security audit3 / 3 scanners passed
Last updatedJuly 23, 2026
Repositorynrwl/nx-ai-agents-config

How do I run build, test, or lint for one or many Nx projects, or only affected ones in CI?

Run single, many, or affected Nx tasks with correct package-manager prefixes and cache or parallel flags.

Who is it for?

Agents operating in Nx monorepos who need task discovery and affected CI runs.

Skip if: Skip for non-Nx repositories or Nx workspace generator authoring.

When should I use this skill?

User asks to run nx tasks, run-many, affected builds, or discover project targets.

What you get

Correctly prefixed Nx commands targeting the right projects with optional cache and parallel controls.

  • nx cli commands
  • task execution output
  • project target listing

Files

SKILL.mdMarkdownGitHub ↗

You can run tasks with Nx in the following way.

Keep in mind that you might have to prefix things with npx/pnpx/yarn if the user doesn't have nx installed globally. Look at the package.json or lockfile to determine which package manager is in use.

For more details on any command, run it with --help (e.g. nx run-many --help, nx affected --help).

Understand which tasks can be run

You can check those via nx show project <projectname> --json, for example nx show project myapp --json. It contains a targets section which has information about targets that can be run. You can also just look at the package.json scripts or project.json targets, but you might miss out on inferred tasks by Nx plugins.

Run a single task

nx run <project>:<task>

where project is the project name defined in package.json or project.json (if present).

Run multiple tasks

nx run-many -t build test lint typecheck

You can pass a -p flag to filter to specific projects, otherwise it runs on all projects. You can also use --exclude to exclude projects, and --parallel to control the number of parallel processes (default is 3).

Examples:

  • nx run-many -t test -p proj1 proj2 — test specific projects
  • nx run-many -t test --projects=*-app --exclude=excluded-app — test projects matching a pattern
  • nx run-many -t test --projects=tag:api-* — test projects by tag

Run tasks for affected projects

Use nx affected to only run tasks on projects that have been changed and projects that depend on changed projects. This is especially useful in CI and for large workspaces.

nx affected -t build test lint

By default it compares against the base branch. You can customize this:

  • nx affected -t test --base=main --head=HEAD — compare against a specific base and head
  • nx affected -t test --files=libs/mylib/src/index.ts — specify changed files directly

Useful flags

These flags work with run, run-many, and affected:

  • --skipNxCache — rerun tasks even when results are cached
  • --verbose — print additional information such as stack traces
  • --nxBail — stop execution after the first failed task
  • --configuration=<name> — use a specific configuration (e.g. production)

Related skills

Forks & variants (3)

Nx Run Tasks has 3 known copies in the catalog totaling 265 installs. They canonicalize to this original listing.

How it compares

Use nx-run-tasks for Nx-specific monorepo command execution rather than generic npm script skills that lack nx affected and show project discovery.

FAQ

How do I see all runnable targets for a project?

Run nx show project PROJECT --json and read the targets section for plugin-inferred tasks.

When should I use nx affected instead of run-many?

In CI or large workspaces to run tasks only on changed projects and their dependents.

What is the default parallel count for run-many?

Three parallel processes unless you pass --parallel with another number.

Is Nx Run Tasks safe to install?

skills.sh reports 3 of 3 security scanners passed. Review the Security Audits panel on this page before installing in production.

DevOps & CI/CDdevopsintegrations

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.