arm run script

This commit is contained in:
lealife
2015-11-29 13:05:26 +08:00
parent c58e6874c2
commit 92576e9239
2 changed files with 24 additions and 1 deletions

@ -122,7 +122,12 @@ function tarRelease()
if [ $1 = "linux" -o $1 = "darwin" ]
then
suffix=""
cp ./bin/run.sh $tmp/leanote/bin/
if [ $2 = "arm" ]
then
cp ./bin/run_arm.sh $tmp/leanote/bin/run.sh
else
cp ./bin/run.sh $tmp/leanote/bin/
fi
else
cp ./bin/run.bat $tmp/leanote/bin/
suffix=".exe"

18
bin/run_arm.sh Normal file

@ -0,0 +1,18 @@
#!/bin/sh
SCRIPTPATH=$(cd "$(dirname "$0")"; pwd)
# set link
path="$SCRIPTPATH/src/github.com/leanote"
if [ ! -d "$path" ]; then
mkdir -p "$path"
fi
rm -rf $SCRIPTPATH/src/github.com/leanote/leanote # 先删除
ln -s ../../../../ $SCRIPTPATH/src/github.com/leanote/leanote
# set GOPATH
export GOPATH=$SCRIPTPATH
script="$SCRIPTPATH/leanote-linux-arm"
chmod 777 $script
$script -importPath github.com/leanote/leanote