Skip to content

Instantly share code, notes, and snippets.

@surajRathi
Created February 13, 2022 10:03
Show Gist options
  • Save surajRathi/1276644f7f2efc415663a681a0cf930f to your computer and use it in GitHub Desktop.
Save surajRathi/1276644f7f2efc415663a681a0cf930f to your computer and use it in GitHub Desktop.
rosremote: Shell Script to setup variables to use rosmaster on the ssh client
#! /usr/bin/zsh
source /opt/ros/noetic/setup.zsh
export ROS_MASTER_URI="http://$(echo $SSH_CLIENT | cut -d ' ' -f 1):11311"
export ROS_HOSTNAME="$(hostname -I | cut -d ' ' -f 1)"
$@
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment