Passa al contenuto principale
Versione: 12.x

pnpm tasks

Added in: v12.6.0

Inspect tasks in concurrency groups.

note

If your package or workspace defines a script named "tasks" in package.json, that script takes precedence when running pnpm tasks. Use pnpm pm tasks to force the built-in command.

Commands

status

Show running and waiting tasks in concurrency groups.

pnpm tasks status [groups...]

Lists the running (active holders) and waiting tasks across concurrency groups, including how long each task has been running or waiting, its process ID, working directory, and its task priority.

Examples

Show all active concurrency groups used by pnpm processes sharing the same stateDir:

pnpm tasks status

If no concurrency groups are currently in use, pnpm outputs:

No concurrency groups are in use.

Inspect specific concurrency groups:

pnpm tasks status cargo typescript

When group names are specified, pnpm outputs the status of only those groups, including idle groups:

cargo
running
build:native 12s
pid 45123 in /workspace/crates/native
waiting
1. test:native 3s priority 2
pid 45201 in /workspace/crates/native
2. bench:native 1s priority 0
pid 45210 in /workspace/crates/native

typescript: idle

Script precedence

If your project defines a "tasks" script in package.json:

# Runs the "tasks" script from package.json
pnpm tasks status

# Runs the built-in pnpm tasks status command
pnpm pm tasks status

See also