nx/docs/shared/cli/run.md
Isaac Mann e717660102
docs(nx-dev): diataxis restructure (#11649)
* docs(nxdev): restructure docs to diataxis style

* docs(nxdev): cleanup

* docs(nxdev): fix links

* chore(nxdev): format

* docs(nxdev): fix broken images

* docs(nxdev): fix links

* docs(nxdev): fix links

* docs(nxdev): fix links

* docs(nxdev): tweaks

* docs(nxdev): redirect rules

* docs(nxdev): fixes
2022-08-29 08:36:55 -04:00

45 lines
887 B
Markdown

---
title: 'run - CLI command'
description: 'Runs an Architect target with an optional custom builder configuration defined in your project.'
---
# run
Runs an Architect target with an optional custom builder configuration defined in your project.
## Usage
```bash
nx run <target> [options]
```
Install `nx` globally to invoke the command directly using `nx`, or use `npx nx`, `yarn nx`, or `pnpx nx`.
### Examples
Run the `build` target for the `myapp` :
```bash
nx run myapp:build
```
Run the `build` target for the `myapp` project with a `production` configuration:
```bash
nx run myapp:build:production
```
## Options
### configuration (-c)
A named builder configuration, defined in the "configurations" section of the workspace configuration file. The builder uses the named configuration to run the given target.
### help
Show help
### version
Show version number