2 Star 4 Fork 5

yc90s / xpub

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
build.sh 742 Bytes
AI 代码解读
一键复制 编辑 原始数据 按行查看 历史
yc90s 提交于 2017-12-08 20:34 . update build.sh
#!/bin/sh
command -v go > /dev/null 2>&1
if [ $? != 0 ]; then
command -v apt-get > /dev/null 2>&1
if [ $? == 0 ]; then
sudo apt-get install golang
else
command -v yum > /dev/null 2>&1
if [ $? == 0 ]; then
sudo yum install golang
fi
fi
fi
# check golang
command -v go > /dev/null 2>&1
if [ $? != 0 ]; then
echo "golang install failed"
exit 1
fi
DIRNAME=$(pwd)
export GOPATH=$DIRNAME
if [ ! -d $GOPATH/bin ]; then
mkdir $GOPATH/bin
fi
export GOBIN=$GOPATH/bin
set -x
go get github.com/mattn/go-colorable
go get github.com/peterh/liner
go get golang.org/x/crypto/ssh
go get golang.org/x/crypto/ssh/terminal
cd src && go build -o $GOBIN/xpub
chmod u+x $GOBIN/xpub
Go
1
https://gitee.com/1050676515/xpub.git
git@gitee.com:1050676515/xpub.git
1050676515
xpub
xpub
master

搜索帮助