Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: document where pixi-global.toml can be found #2304

Merged
merged 1 commit into from
Oct 17, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 31 additions & 5 deletions docs/features/global_tools.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,12 @@
With `pixi global`, users can manage globally installed tools in a way that makes them available from any directory.
This means that the pixi environment will be placed in a global location, and the tools will be exposed to the system `PATH`, allowing you to run them from the command line.

!!! note
The design for global tools is still in progress, and the commands and behavior may change in future releases.
The proposal for the global tools feature can be found [here](../design_proposals/pixi_global_manifest.md).

## The Global Manifest
Since `v0.33.0` pixi has a new manifest file that will be created in the global directory (default: `$HOME/.pixi/manifests/pixi-global.toml`).
Since `v0.33.0` pixi has a new manifest file that will be created in the global directory.
This file will contain the list of environments that are installed globally, their dependencies and exposed binaries.
The manifest can be edited, synced, checked in to a version control system, and shared with others.


A simple version looks like this:
```toml
[envs.vim]
Expand All @@ -34,6 +31,35 @@ exposed = { python310 = "python" } # (3)!
2. The exposed binaries are the ones that will be available in the system path. `vim` has multiple and all of them are exposed.
3. Here python is exposed as `python310` to avoid conflicts with other python installations. You can give it any name you want.

### Manifest locations

The manifest can be found at the following locations depending on your operation system.

=== "Linux"
Copy link
Contributor

Choose a reason for hiding this comment

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

wdyt about using heading or bold "Linux" here?

like

Linux

or

Linux

I think it looks more easy to read

Copy link
Contributor

Choose a reason for hiding this comment

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

This should be aligned with the other tabbed headings so it stays selected, If you select linux in one page it will be remembered over all pages.

Copy link
Contributor

Choose a reason for hiding this comment

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

image
this is how it is looking in markdown for me, but maybe I'm missing something

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@nichmor Did you run pixi run docs? This syntax is mkdocs specific


| **Priority** | **Location** | **Comments** |
|--------------|------------------------------------------------------------------------|------------------------------------------------------------------------------------|
| 1 | `$HOME/.pixi/manifests/pixi-global.toml` | User-specific manifest |
| 2 | `$PIXI_HOME/manifests/pixi-global.toml` | Global manifest in the user home directory. `PIXI_HOME` defaults to `~/.pixi` |

=== "macOS"

| **Priority** | **Location** | **Comments** |
|--------------|------------------------------------------------------------------------|------------------------------------------------------------------------------------|
| 1 | `$HOME/.pixi/manifests/pixi-global.toml` | User-specific manifest |
| 2 | `$PIXI_HOME/manifests/pixi-global.toml` | Global manifest in the user home directory. `PIXI_HOME` defaults to `~/.pixi` |

=== "Windows"

| **Priority** | **Location** | **Comments** |
|--------------|------------------------------------------------------------------------|------------------------------------------------------------------------------------------------|
| 1 | `%USERPROFILE%\.pixi\manifests\pixi-global.toml` | User-specific manifest |
| 2 | `$PIXI_HOME\manifests/pixi-global.toml` | Global manifest in the user home directory. `PIXI_HOME` defaults to `%USERPROFILE%/.pixi` |

!!! note
If multiple locations exist, the manifest with the highest priority will be used.


### Channels
The channels are the conda channels that will be used to search for the packages.
There is a priority to these, so the first one will have the highest priority, if a package is not found in that channel the next one will be used.
Expand Down