upgrade setup script to v1.15.2

This commit is contained in:
c9s 2021-04-28 17:56:46 +08:00
parent 0aabbc850a
commit 5cddec93ef
4 changed files with 30 additions and 11 deletions

View File

@ -1,13 +1,32 @@
#!/bin/bash #!/bin/bash
set -e
osf=$(uname | tr '[:upper:]' '[:lower:]') osf=$(uname | tr '[:upper:]' '[:lower:]')
version=v1.6.0 version=v1.15.2
dist_file=bbgo-$version-$osf-amd64.tar.gz
if [[ -n $1 ]] ; then RED='\033[0;31m'
version=$1 GREEN='\033[0;32m'
fi YELLOW='\033[0;33m'
NC='\033[0m' # No Color
echo "downloading bbgo $version" function warn()
curl -L -o bbgo https://github.com/c9s/bbgo/releases/download/$version/bbgo-$osf {
echo -e "${YELLOW}$@${NC}"
}
function error()
{
echo -e "${RED}$@${NC}"
}
function info()
{
echo -e "${GREEN}$@${NC}"
}
info "downloading..."
curl -O -L https://github.com/c9s/bbgo/releases/download/$version/$dist_file
tar xzf $dist_file
mv bbgo-$osf bbgo
chmod +x bbgo chmod +x bbgo
info "downloaded successfully"
echo "bbgo is downloaded at ./bbgo"

View File

@ -1,7 +1,7 @@
#!/bin/bash #!/bin/bash
set -e set -e
osf=$(uname | tr '[:upper:]' '[:lower:]') osf=$(uname | tr '[:upper:]' '[:lower:]')
version=v1.14.0 version=v1.15.2
dist_file=bbgo-$version-$osf-amd64.tar.gz dist_file=bbgo-$version-$osf-amd64.tar.gz
RED='\033[0;31m' RED='\033[0;31m'

View File

@ -1,7 +1,7 @@
#!/bin/bash #!/bin/bash
set -e set -e
osf=$(uname | tr '[:upper:]' '[:lower:]') osf=$(uname | tr '[:upper:]' '[:lower:]')
version=v1.14.0 version=v1.15.2
dist_file=bbgo-$version-$osf-amd64.tar.gz dist_file=bbgo-$version-$osf-amd64.tar.gz
RED='\033[0;31m' RED='\033[0;31m'

View File

@ -1,6 +1,6 @@
#!/bin/bash #!/bin/bash
osf=$(uname | tr '[:upper:]' '[:lower:]') osf=$(uname | tr '[:upper:]' '[:lower:]')
version=v1.6.0 version=v1.15.2
echo "Downloading bbgo" echo "Downloading bbgo"
curl -L -o bbgo https://github.com/c9s/bbgo/releases/download/$version/bbgo-$osf curl -L -o bbgo https://github.com/c9s/bbgo/releases/download/$version/bbgo-$osf