Skip to content

Commit

Permalink
finish_slam.sh: add mkdir
Browse files Browse the repository at this point in the history
  • Loading branch information
lixiang committed Jun 25, 2021
1 parent 4257066 commit edfd834
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
6 changes: 6 additions & 0 deletions finish_slam_2d.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ source install_isolated/setup.bash
map_dir="${HOME}/carto_ws/map"
map_name="2d-1"

# 检查文件夹是否存在, 如果不存在就创建文件夹
if [ ! -d "$map_dir" ];then
echo "文件夹不存在, 正在创建文件夹"
mkdir -p $map_dir
fi


# finish slam
rosservice call /finish_trajectory 0
Expand Down
5 changes: 5 additions & 0 deletions finish_slam_3d.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ source install_isolated/setup.bash
map_dir="${HOME}/carto_ws/map"
map_name="3d-1"

# 检查文件夹是否存在, 如果不存在就创建文件夹
if [ ! -d "$map_dir" ];then
echo "文件夹不存在, 正在创建文件夹"
mkdir -p $map_dir
fi

# finish slam
rosservice call /finish_trajectory 0
Expand Down

0 comments on commit edfd834

Please sign in to comment.