Skip to main content

jnc lock

Solves all environments defined in the workspace manifest and writes an updated pixi.lock file. Unlike jnc install, this command does not install any packages into an environment prefix — it only computes and persists the dependency resolution. This is useful in CI workflows, validation checks, or when you want to preview what would change before installing.

Usage

jnc lock [OPTIONS]

Options

OptionDescription
--jsonOutput the changes to the lock file in JSON format.
--checkCheck if the lock file would change. Exits with a non-zero code if changes are detected. Useful in CI.
--dry-runCompute the lock file without writing to disk. Implies --no-install.
--no-installDo not install the environment (default behavior for lock, but can be made explicit).

Global Options

OptionDescription
-m, --manifest-path <PATH>Path to pixi.toml, pyproject.toml, or the workspace directory.

Examples

Update the lock file

jnc lock

Check if the lock file is up-to-date (CI use)

jnc lock --check

Preview lock file changes without writing

jnc lock --dry-run

Output lock file changes as JSON

jnc lock --json