Skip to main content
Removes dependencies from a global environment. To remove the entire environment, use pixi global uninstall instead.

Usage

Alias: pixi g remove, pixi g rm

Arguments

string
required
Package(s) to remove from the environment.Multiple packages can be specified.

Options

string
required
The environment from which dependencies should be removed.

Examples

Remove a package from an environment

Remove multiple packages

How It Works

  1. Removes the package from the environment’s manifest
  2. Removes exposed executables that belong to the package
  3. Syncs the environment to reflect the changes
  4. Updates shortcuts if applicable
The --environment flag is required. If you want to remove the entire environment, use pixi global uninstall instead.

Use Cases

Clean Up Dependencies

Remove packages you no longer need:

Remove Additional Dependencies

If you installed packages with --with, you can remove them:

What Gets Removed

  • The package entry from the environment’s manifest
  • Exposed executables from that package
  • The package and its unique dependencies from the environment

What Doesn’t Get Removed

  • Shared dependencies (used by other packages in the environment)
  • The environment itself (use pixi global uninstall for that)

Error Handling

If the removal fails, pixi will attempt to revert the changes:
Use pixi g rm as a shorthand for pixi global remove.

Viewing Changes

After removal, you can check the environment:

Complete Example

Differences from pixi global uninstall

Syncing After Removal

The environment is automatically synced after removal. If you want to ensure everything is in sync: