openrr / urdf-rs

URDF parser for Rust
Apache License 2.0
30 stars 11 forks source link

Fall back to xacro binary in case rosrun doesn't exists #45

Closed JafarAbdi closed 2 years ago

JafarAbdi commented 2 years ago

Thanks for the awesome libraries!

When sourcing /opt/ros/.../setup.bash it update the PATH environment variable to have /opt/ros/.../bin which contains the xacro binary, this is needed to make urdf-viz work with ROS2.

Another solution would be to always use xacro since the path to the binary directory will be set for ROS1, too, which mean we could use xacro directly for both versions.

OTL commented 2 years ago

Good catch! I think your second option is enough, I mean remove rosrun completely. (it's ok to merge this PR anyway)