Back to Pixi

Home

docs/index.md

0.67.29.9 KB
Original Source

Pixi

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

Highlights


Quick Demo

Project setup is a breeze with Pixi.

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

Install your favorite tools with a single command.

shell
pixi global install gh nvim ipython btop ripgrep


How Tools Compare to Pixi

Builtin Core FeaturesPixiCondaPipPoetryuv
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 30,000 packages.

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


Installation

To install pixi, run:

=== "Linux & macOS" bash curl -fsSL https://pixi.sh/install.sh | sh

=== "Windows" Download installer{ .md-button }

Or run:

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

!!! tip "Now restart your terminal or shell!" The installation needs to become effective by restarting your terminal or sourcing your shell.

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

See all installation options β†’


Getting Started

=== "Python" 1. Initialize a workspace: pixi init hello-world cd hello-world 2. Add dependencies into the default environment: pixi add cowpy python 3. Create your script: py title="hello.py" --8<-- "docs/source_files/pixi_workspaces/introduction/deps_add/hello.py" 5. Add a task: pixi task add start python hello.py 6. Run the task: pixi run start ✨ Pixi task (start): python hello.py __________________ < Hello Pixi fans! > ------------------ \ ^__^ \ (oo)\_______ (__)\ )\/\ ||----w | || || 7. Enter the shell into the environment: pixi shell python hello.py exit

More details on how to use Pixi with Python can be found in the [Python tutorial](python/tutorial.md).

=== "Rust" 1. Initialize a workspace: pixi init pixi-rust cd pixi-rust 2. Add dependencies: pixi add rust 3. Create your workspace: pixi run cargo init 4. Add a task: pixi task add start cargo run 5. Run the task: pixi run start ✨ Pixi task (start): cargo run Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.02s Running `target/debug/pixi-rust` Hello, world!

This is more of an example to show off how easy it is to use Pixi with Rust.
Not a recommended way to build Rust projects.
More details on how to use Pixi with Rust can be found in the [Rust tutorial](tutorials/rust.md).

=== "Node.js" 1. Initialize a workspace: pixi init pixi-node cd pixi-node 2. Add dependencies: pixi add nodejs 3. Create your script: js title="hello.js" console.log("Hello Pixi fans!"); 4. Add a task: pixi task add start "node hello.js" 5. Run the task: pixi run start ✨ Pixi task (start): node hello.js Hello Pixi fans!

=== "ROS2"

1. **Initialize a workspace:**
    ```
    pixi init pixi-ros2 -c https://prefix.dev/conda-forge -c "https://prefix.dev/robostack-humble"
    cd pixi-ros2
    ```
2. **Add dependencies:**
    ```
    pixi add ros-humble-desktop
    ```

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

3. **Start Rviz**
    ```
    pixi run rviz2
    ```

More details on how to use Pixi with ROS2 can be found in the [ROS2 tutorial](tutorials/ros2.md).

=== "DevOps" 1. Install all your favorite tools with a single command: shell pixi global install terraform ansible k9s make 2. Use them everywhere: shell ansible --version terraform --version k9s version make --version


What Developers Say

<div class="quote-scroll-wrapper"> <div class="quote-scroll"> <div class="quote-card"> <p>"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."</p> <strong>Guillaume Lemaitre</strong> – <a href="https://scikit-learn.org">scikit-learn</a> </div> <div class="quote-card"> <p>"I can’t stress enough how much I love using Pixi global as a package manager for my daily CLI tools. With the global manifest, even sharing my setup across machines is trivial!"</p> <strong>Matthew Feickert</strong> – <a href="https://www.wisc.edu/">University of Wisconsin–Madison</a> </div> <div class="quote-card"> <p>"We are changing how we manage ROS dependencies on Windows. We will be using Pixi to install and manage dependencies from conda. I'm pretty excited about how much easier it will be for users going forward."</p> <strong>Michael Carroll</strong> – <a href="https://www.ros.org/">Project Lead ROS</a> </div> </div> </div>
  • GitHub: Pixi source code, feel free to leave a star!
  • Discord: Join our community and ask questions.
  • Prefix.dev: The company behind Pixi, building the future of package management.
  • conda-forge: Community-driven collection of recipes for the conda package manager.
  • Rattler: Everything conda but built in Rust. Backend of Pixi.
  • rattler-build: A blazing fast build system for conda packages.