Files
leanote/bin/run.sh

24 lines
545 B
Bash
Raw Normal View History

2014-05-07 13:01:21 +08:00
#!/bin/sh
SCRIPTPATH=$(cd "$(dirname "$0")"; pwd)
# set link
2014-05-09 15:37:36 +08:00
#
#path="$SCRIPTPATH/src/github.com/leanote"
#if [ ! -d "$path" ]; then
# mkdir -p "$path"
#fi
# ln -s ../../../../ $SCRIPTPATH/src/github.com/leanote/leanote
2014-05-07 13:01:21 +08:00
# set GOPATH
export GOPATH=$GOPATH:$SCRIPTPATH
# run
osName=`uname`
if [ $osName == "Darwin" ]; then
2014-05-07 16:14:34 +08:00
chmod 777 "$SCRIPTPATH/leanote-mac"
2014-05-07 13:01:21 +08:00
"$SCRIPTPATH/leanote-mac" -importPath github.com/leanote/leanote
else
2014-05-07 16:14:34 +08:00
chmod 777 "$SCRIPTPATH/leanote-linux"
2014-05-07 13:01:21 +08:00
"$SCRIPTPATH/leanote-linux" -importPath github.com/leanote/leanote
2014-05-09 15:37:36 +08:00
fi