I'm developing a ROS2-application in python and the source code is on the robot and needs a specific environment to run/debug. This environment is setup by sourcing a file, so if I run it manually, it boils down to
ssh user@robotsource foo/setup.bashpython3 fancy.py
I tried to integrate the source-command as preLaunchTask, but these tasks are executed in their own shell and then a new one (with new environment variables) is started to run the program and I can't find the modules that are added with the source-command.
I assume there is a way to debug in the same terminal in which I ran my preLaunchTasks, but I didn't fine the right config yet.