forked from ipa320/setup
-
Notifications
You must be signed in to change notification settings - Fork 0
/
copy_pkg_to_commercial.sh
executable file
·40 lines (33 loc) · 1.07 KB
/
copy_pkg_to_commercial.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#!/usr/bin/env bash
# Script to copy binaries to the cob_commercial stack.
# checking input parameters
if [ "$#" -ge 2 ]; then
echo "ERROR: Wrong number of parameters"
echo "Usage: copy_pkg_to_commercial.sh PACKAGE"
exit 1
elif [ "$1" = "cob_platform_ctrl" ]; then
PACKAGE=$1
elif [ "$1" = "cob_sensor_fusion" ]; then
PACKAGE=$1
elif [ "$1" = "cob_object_detection" ]; then
PACKAGE=$1
else
echo "ERROR: package <<"$1">> not supported, choose one of"
echo " * cob_platform_ctrl"
echo " * cob_sensor_fusion"
echo " * cob_object_detection"
echo "aborting..."
exit 1
fi
echo "------------------------------------------------------"
echo "Copying package <<"$PACKAGE">> to cob_commercial"
echo "------------------------------------------------------"
echo ""
# setup ROS_PACKAGE_PATH
source /opt/ros/diamondback/setup.bash
export ROS_PACKAGE_PATH=~/git/cob3_intern:$ROS_PACKAGE_PATH
# copy binaries
cp $(rospack find $PACKAGE)/ros/bin/* ~/git/care-o-bot/cob_commercial/$PACKAGE/ros/bin -rf
# strip binaries
strip ~/git/care-o-bot/cob_commercial/$PACKAGE/ros/bin/*
echo "done."