Skip to content

pixi remove#

Removes dependencies from the workspace

If the project manifest is a pyproject.toml, removing a pypi dependency with the --pypi flag will remove it from either

  • the native pyproject project.dependencies array or the native project.optional-dependencies table (if a feature is specified)
  • pixi pypi-dependencies tables of the default or a named feature (if a feature is specified)

Usage#

pixi remove [OPTIONS] <SPEC>...

Arguments#

  • <SPEC>
    The dependency as names, conda MatchSpecs or PyPi requirements
    May be provided more than once.
    required: true

Options#

  • --pypi
    The specified dependencies are pypi dependencies. Conflicts with host and build
  • --platform (-p) <PLATFORM>
    The platform for which the dependency should be modified. Must be the name of a platform already defined in the workspace
    May be provided more than once.
  • --feature (-f) <FEATURE>
    The feature for which the dependency should be modified
    default: default
  • --environment (-e) <ENVIRONMENT>
    The environment for which the dependency should be modified. The dependency is written to the content defined inline on the environment, creating the environment if it does not exist

Config Options#

Git Options#

Update Options#

  • --no-install
    Don't modify the environment, only modify the lock file
    env: PIXI_NO_INSTALL
  • --frozen
    Install the environment as defined in the lock file, doesn't update lock file if it isn't up-to-date with the manifest file
    env: PIXI_FROZEN
  • --locked
    Check if lock file is up-to-date before installing the environment, aborts when lock file isn't up-to-date with the manifest file
    env: PIXI_LOCKED

Global Options#

Description#

Removes dependencies from the workspace.

If the workspace manifest is a pyproject.toml, removing a pypi dependency with the --pypi flag will remove it from either

  • the native pyproject project.dependencies array or, if a feature is specified, the native project.optional-dependencies table
  • pixi pypi-dependencies tables of the default feature or, if a feature is specified, a named feature

Examples#

pixi remove numpy
pixi remove numpy pandas pytorch
pixi remove --manifest-path ~/myworkspace/pixi.toml numpy
pixi remove --host python
pixi remove --build cmake
pixi remove --pypi requests
pixi remove --platform osx-64 --build clang
pixi remove --feature featurex clang
pixi remove --environment dev clang
pixi remove --feature featurex --platform osx-64 clang
pixi remove --feature featurex --platform osx-64 --build clang
pixi remove --no-install numpy