Skip to content

feat: add --path to the pixi add command - #6904

Merged
ruben-arts merged 3 commits into
prefix-dev:mainfrom
ruben-arts:feature/pixi-add-path
Aug 27, 2026
Merged

feat: add --path to the pixi add command#6904
ruben-arts merged 3 commits into
prefix-dev:mainfrom
ruben-arts:feature/pixi-add-path

Conversation

@ruben-arts

Copy link
Copy Markdown
Contributor

Description

This PR add pixi add --path.

It works for both conda and pypi dependencies.

If you use it for conda dependencies and the preview = ["pixi-build"] flag doesn't exist you'll get an interactive request whether you want to add it.

It accepts pixi add --path /bla/package/pixi.toml package-name but will save it as package-name = { path = "../package" } as absolute paths don't work nicely in the manifest.

How Has This Been Tested?

I've tested it by adding some local package on my machine to a new pixi project and I couldn't break it.
e.g.:

pixi add --path ~/dev/pixi pixi
pixi add --path ~/dev/vinca vinca --pypi
pixi add --path ~/dev/ros_ws/src/common/package.xml ros-jazzy-common

AI Disclosure

  • This PR contains AI-generated content.
    • I have tested any AI-generated content in my PR.
    • I take responsibility for any AI-generated content in my PR.

Tools: Codex

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added sufficient tests to cover my changes.
  • I have verified that changes that would impact the JSON schema have been made in schema/model.py.

Comment thread docs/reference/cli/pixi/add.md Outdated
Comment on lines +154 to +155
absolute input path does not become machine-specific manifest data. A direct
`pixi.toml` or `pyproject.toml` input is stored as its containing directory.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't get this sentence

@ruben-arts
ruben-arts enabled auto-merge (squash) August 27, 2026 15:01
@ruben-arts
ruben-arts merged commit 82c7096 into prefix-dev:main Aug 27, 2026
38 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants