Skip to content

Commit

Permalink
Merge pull request start-jsk#96 from garaemon/add-env-hooks-to-setup-…
Browse files Browse the repository at this point in the history
…utility-shell-funcs

[jsk_hrp2_ros_bridge] Add env-hooks to define utility functions like rossethrp2016v
  • Loading branch information
garaemon committed Apr 5, 2015
2 parents b757ad1 + 3fdac3d commit b6bf0ac
Show file tree
Hide file tree
Showing 3 changed files with 77 additions and 0 deletions.
3 changes: 3 additions & 0 deletions jsk_hrp2_ros_bridge/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -97,3 +97,6 @@ rtmbuild_genidl()

# generate bridge
rtmbuild_genbridge()

catkin_add_env_hooks(99.jsk_hrp2_ros_bridge SHELLS bash zsh DIRECTORY
${CMAKE_CURRENT_SOURCE_DIR}/env-hooks)
37 changes: 37 additions & 0 deletions jsk_hrp2_ros_bridge/env-hooks/99.jsk_hrp2_ros_bridge.bash
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
#!/bin/bash
# -*- mode: shell-script -*-

function rossethrp2017() {
rossetmaster hrp2017v 10017
export ROBOT=HRP2JSKNTS
export HRP2NO=17
rossetip
}

function rossethrp2016() {
rossetmaster hrp2016v 10016
export ROBOT=HRP2JSKNT
export HRP2NO=16
rossetip
}

function rossethrp2007() {
rossetmaster hrp2007v 10007
export ROBOT=HRP2JSK
export HRP2NO=7
rossetip
}

function rossethrp2008() {
rossetmaster hrp2008v 10008
export ROBOT=HRP2W
export HRP2NO=8
rossetip
}

function rossethrp2018() {
rossetmaster hrp2018v 10018
export ROBOT=HRP2W
export HRP2NO=8
rossetip
}
37 changes: 37 additions & 0 deletions jsk_hrp2_ros_bridge/env-hooks/99.jsk_hrp2_ros_bridge.zsh
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
#!/bin/zsh
# -*- mode: shell-script -*-

function rossethrp2017() {
rossetmaster hrp2017v 10017
export ROBOT=HRP2JSKNTS
export HRP2NO=17
rossetip
}

function rossethrp2016() {
rossetmaster hrp2016v 10016
export ROBOT=HRP2JSKNT
export HRP2NO=16
rossetip
}

function rossethrp2007() {
rossetmaster hrp2007v 10007
export ROBOT=HRP2JSK
export HRP2NO=7
rossetip
}

function rossethrp2008() {
rossetmaster hrp2008v 10008
export ROBOT=HRP2W
export HRP2NO=8
rossetip
}

function rossethrp2018() {
rossetmaster hrp2018v 10018
export ROBOT=HRP2W
export HRP2NO=8
rossetip
}

0 comments on commit b6bf0ac

Please sign in to comment.