Pixi: Fast, modern, and reproducible package management tool

__rito__1 pts0 comments

Home

Skip to content

You're not viewing the latest version.

Click here to go to latest.

Initializing search

GitHub

Robotics

Getting Started

Tutorials

ROS 2

Rust

Switching From...

Multi Environment

Global Tools

Import Environments

Concepts

Building

Dependency Types

Workspace Dependencies

Build Backends

Key Concepts

Package Source

Dev Packages

Distributing

Integration

Continuous Integration

Extensions

Third Party

Advanced

Reference

Misc

Pixi#

Pixi is a fast, modern, and reproducible package management tool for developers of all backgrounds.

Highlights#

πŸ”„ Reproducibility

Isolated, easily recreated environments with lock files built-in

πŸ› οΈ Tasks

Manage complex pipelines effortlessly.

🌐 Multi Platform

Works on Linux, macOS, Windows, and more.

🧩 Multiple Environments

Compose multiple environments in one manifest.

🐍 Python

Support for pyproject.toml and PyPI through uv.

πŸ’Ύ Disk Efficient<br>Environments share files through hard links or reflinks, so packages are stored only once.

🌍 Global Tools<br>Install global tools, safely isolated. Replacing apt, homebrew, winget.

Quick Demo#

Project setup is a breeze with Pixi.

pixi init hello-world<br>cd hello-world<br>pixi add python<br>pixi run python -c 'print("Hello World!")'

Install your favorite tools with a single command.

pixi global install gh nvim ipython btop ripgrep

How Tools Compare to Pixi#

Builtin Core Features<br>Pixi<br>Conda<br>Pip<br>Poetry<br>uv

Installs Python

Supports Multiple Languages

Lockfiles

Task runner

Workspace Management

Available Software#

Pixi defaults to the biggest Conda package repository , conda-forge, which contains over<br>30,000 packages .

Python : python, scikit-learn, pytorch

C/C++ : clang, boost, opencv, ninja

Java : openjdk, gradle, maven

Rust : rust, cargo-edit, cargo-insta

Node.js : nodejs, bun, pnpm, eslint

Cli Tools : git, gh, ripgrep, make

And browse the thousands more on prefix.dev, or host your own channels

Installation#

To install pixi, run:

Linux & macOSWindows

curl -fsSL https://pixi.sh/install.sh | sh

Download installer

Or run:

powershell -ExecutionPolicy ByPass -c "irm -useb https://pixi.sh/install.ps1 | iex"

Now restart your terminal or shell!

The installation needs to become effective by restarting your terminal or sourcing your shell.

Don't trust our link? Check the script!<br>You can check the installation sh script: download and the ps1: download.<br>The scripts are open source and available on GitHub.

See all installation options β†’

Getting Started#

PythonRustNode.jsROS2DevOps

Initialize a workspace:<br>pixi init hello-world<br>cd hello-world

Add dependencies into the default environment:<br>pixi add cowpy python

Create your script:<br>hello.pyfrom cowpy.cow import Cowacter

message = Cowacter().milk("Hello Pixi fans!")<br>print(message)

Add a task:<br>pixi task add start python hello.py

Run the task:<br>pixi run start

✨ Pixi task (start): python hello.py

\ ^__^<br>\ (oo)\_______<br>(__)\ )\/\<br>||----w |<br>|| ||

Enter the shell into the environment:<br>pixi shell<br>python hello.py<br>exit

More details on how to use Pixi with Python can be found in the Python tutorial.

Initialize a workspace:<br>pixi init pixi-rust<br>cd pixi-rust

Add dependencies:<br>pixi add rust

Create your workspace:<br>pixi run cargo init

Add a task:<br>pixi task add start cargo run

Run the task:<br>pixi run start

✨ Pixi task (start): cargo run<br>Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.02s<br>Running `target/debug/pixi-rust`<br>Hello, world!

This is more of an example to show off how easy it is to use Pixi with Rust.<br>Not a recommended way to build Rust projects.<br>More details on how to use Pixi with Rust can be found in the Rust tutorial.

Initialize a workspace:<br>pixi init pixi-node<br>cd pixi-node

Add dependencies:<br>pixi add nodejs

Create your script:<br>hello.jsconsole.log("Hello Pixi fans!");

Add a task:<br>pixi task add start "node hello.js"

Run the task:<br>pixi run start

✨ Pixi task (start): node hello.js<br>Hello Pixi fans!

Initialize a workspace:<br>pixi init pixi-ros2 -c https://prefix.dev/conda-forge -c "https://prefix.dev/robostack-humble"<br>cd pixi-ros2

Add dependencies:<br>pixi add ros-humble-desktop

This might take a minute<br>Depending on your internet connection, this will take a while to install, as it will download the entire ROS2 desktop package.

Start Rviz<br>pixi run rviz2

More details on how to use Pixi with ROS2 can be found in the ROS2 tutorial.

Install all your favorite tools with a single command:<br>pixi global install terraform ansible k9s make

Use them everywhere:<br>ansible --version<br>terraform --version<br>k9s version<br>make --version

What Developers Say#

"Pixi is my tool of choice for Python environment management. It has significantly reduced boilerplate by offering seamless support for both PyPI and conda-forge indexes - a critical requirement in my workflow."

Guillaume Lemaitre – scikit-learn

"I can’t stress enough how much I love using Pixi global as a package manager for my daily CLI tools. With the global...

pixi hello python task rust start

Related Articles