MYNT-EYE-S-SDK/scripts/open.sh

20 lines
356 B
Bash
Raw Normal View History

2018-03-09 05:42:45 +02:00
#!/usr/bin/env bash
2018-03-08 09:54:14 +02:00
BASE_DIR=$(cd "$(dirname "$0")" && pwd)
source "$BASE_DIR/common/echo.sh"
source "$BASE_DIR/common/host.sh"
if [ "$HOST_OS" = "Linux" ]; then
OPEN="xdg-open"
elif [ "$HOST_OS" = "Mac" ]; then
OPEN="open"
elif [ "$HOST_OS" = "Win" ]; then
OPEN="start"
else
_echo_e "Unknown host os :("
exit 1
fi
[ $# -gt 0 ] && $OPEN "$@"