Skip to content

Commit

Permalink
Merge branch 'feature/pixi-build' into feat/actual-build-progress
Browse files Browse the repository at this point in the history
  • Loading branch information
tdejager committed Oct 18, 2024
2 parents 5981e76 + 2d085b3 commit fb3e887
Show file tree
Hide file tree
Showing 149 changed files with 82,248 additions and 31,128 deletions.
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"

| **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
58 changes: 55 additions & 3 deletions examples/turtlesim/README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
# Simple ROS2 turtlesim example
# Simple ROS turtlesim example

Run this in two terminals.
## To run the ROS2 humble example
Run this in **two** terminals.
```shell
pixi run start
```
And
Select the `default` environment for all of the `humble` examples.

And then
```shell
pixi run teleop
```
Expand All @@ -15,3 +18,52 @@ There you can run any of the commands available in the environment.
pixi shell
ros2 topic echo /turtle1/cmd_vel
```

### Now run a script to visualize the turtle in rviz
Run this in **two** more terminals.
```shell
pixi run rviz
```

```shell
pixi run viz
```

## To run the ROS1 Noetic example

Run this in **three** terminals.
```shell
# Start roscore
pixi run -e noetic core
```
or without `-e noetic` and select the `noetic` environment for all of the `noetic` examples.

```shell
# Start turtlesim
pixi run -e noetic start
```

```shell
pixi run -e noetic teleop
```

It is also possible to start a shell in the environment.
There you can run any of the commands available in the environment.
```shell
pixi shell -e noetic
rostopic echo /turtle1/cmd_vel
```

### Now run a script to visualize the turtle in rviz
Run this in **two** more terminals.
```shell
pixi run -e noetic rviz
```

```shell
pixi run -e noetic viz
```

Add the visual marker for the turtle to the displays in rviz.

If you now teleop the turtle, you should see it move in rviz aswell now.
Loading

0 comments on commit fb3e887

Please sign in to comment.