#!/bin/bash
source /home/user/AFROS/catkin_ws/devel/setup.bash
source /opt/ros/melodic/setup.bash
roslaunch /opt/ros/melodic/launchfile.launch
I have this as my bash file that I would like to use to execute a launch file. I am able to launch the launchfile using
roslaunch launchfile.launch
just fine, but if I use my bash file then I get the following error:
ERROR: cannot launch node of type [ros_core/connection_commander_node]: ros_core
ROS path [0]=/opt/ros/melodic/share/ros
ROS path [1]=/opt/ros/melodic/share
ERROR: cannot launch node of type [ros_core/state_machine_commander_node]: ros_core
ROS path [0]=/opt/ros/melodic/share/ros
ROS path [1]=/opt/ros/melodic/share