Skip to content

Commit

Permalink
fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
traversaro authored Apr 24, 2024
1 parent 2e6defa commit f37edb3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions conda/multisheller/matlab-whole-body-simulator_activate.msh
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,22 @@ if_(is_set("COMSPEC")).then_([
sys.list_append("YARP_DATA_DIRS", path.join(env("CONDA_PREFIX"), "Library\\share\\RRbot")),
sys.list_append("ROS_PACKAGE_PATH", path.join(env("CONDA_PREFIX"), "Library\\share")),
sys.list_append("AMENT_PREFIX_PATH", path.join(env("CONDA_PREFIX"), "Library")),
sys.list_append("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "Library\\share\\RRbot\\robots"))
sys.list_append("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "Library\\share\\RRbot\\robots")),
sys.list_append("GZ_SIM_RESOURCE_PATH", path.join(env("CONDA_PREFIX"), "Library\\share\\RRbot\\robots"))
]).else_([
sys.list_append("YARP_DATA_DIRS", path.join(env("CONDA_PREFIX"), "share/RRbot")),
sys.list_append("ROS_PACKAGE_PATH", path.join(env("CONDA_PREFIX"), "share")),
sys.list_append("AMENT_PREFIX_PATH", env("CONDA_PREFIX")),
sys.list_append("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "share/RRbot/robots"))
sys.list_append("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "share/RRbot/robots")),
sys.list_append("GZ_SIM_RESOURCE_PATH", path.join(env("CONDA_PREFIX"), "share/RRbot/robots"))
])

# For some reason setting two times the same variable inside the same if does not work in command prompt
# As a workaround, we move each GAZEBO_MODEL_PATH and GZ_SIM_RESOURCE_PATH set to a separate if
if_(is_set("COMSPEC")).then_([
sys.list_append("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "Library\\share"))
sys.list_append("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "Library\\share")),
sys.list_append("GZ_SIM_RESOURCE_PATH", path.join(env("CONDA_PREFIX"), "Library\\share"))
]).else_([
sys.list_append("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "share"))
sys.list_append("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "share")),
sys.list_append("GZ_SIM_RESOURCE_PATH", path.join(env("CONDA_PREFIX"), "share"))
])
8 changes: 4 additions & 4 deletions conda/multisheller/matlab-whole-body-simulator_deactivate.msh
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,22 @@ if_(is_set("COMSPEC")).then_([
sys.list_remove("YARP_DATA_DIRS", path.join(env("CONDA_PREFIX"), "Library\\share\\RRbot")),
sys.list_remove("ROS_PACKAGE_PATH", path.join(env("CONDA_PREFIX"), "Library\\share")),
sys.list_remove("AMENT_PREFIX_PATH", path.join(env("CONDA_PREFIX"), "Library")),
sys.list_remove("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "Library\\share\\RRbot\\robots"))
sys.list_remove("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "Library\\share\\RRbot\\robots")),
sys.list_remove("GZ_SIM_RESOURCE_PATH", path.join(env("CONDA_PREFIX"), "Library\\share\\RRbot\\robots"))
]).else_([
sys.list_remove("YARP_DATA_DIRS", path.join(env("CONDA_PREFIX"), "share/RRbot")),
sys.list_remove("ROS_PACKAGE_PATH", path.join(env("CONDA_PREFIX"), "share")),
sys.list_remove("AMENT_PREFIX_PATH", env("CONDA_PREFIX")),
sys.list_remove("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "share/RRbot/robots"))
sys.list_remove("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "share/RRbot/robots")),
sys.list_remove("GZ_SIM_RESOURCE_PATH", path.join(env("CONDA_PREFIX"), "share/RRbot/robots"))
])

# For some reason setting two times the same variable inside the same if does not work in command prompt
# As a workaround, we move each GAZEBO_MODEL_PATH and GZ_SIM_RESOURCE_PATHset to a separate if
if_(is_set("COMSPEC")).then_([
sys.list_remove("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "Library\\share"))
sys.list_remove("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "Library\\share")),
sys.list_remove("GZ_SIM_RESOURCE_PATH", path.join(env("CONDA_PREFIX"), "Library\\share"))
]).else_([
sys.list_remove("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "share"))
sys.list_remove("GAZEBO_MODEL_PATH", path.join(env("CONDA_PREFIX"), "share")),
sys.list_remove("GZ_SIM_RESOURCE_PATH", path.join(env("CONDA_PREFIX"), "share"))
])

0 comments on commit f37edb3

Please sign in to comment.