diff options
| author | ruki <[email protected]> | 2020-02-08 00:44:51 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2020-02-07 22:29:08 +0800 |
| commit | 81bd3dc5bfa0965ea01e1ce51a8f09fac3d9a7d0 (patch) | |
| tree | c971282df4f09d60ad64abf5947c20a7251bcd73 /scripts | |
| parent | 934060abc30c69df6ec9ae1f9fa8ec4e7d99dab0 (diff) | |
show download progress for get.sh
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/get.sh | 26 |
1 files changed, 17 insertions, 9 deletions
diff --git a/scripts/get.sh b/scripts/get.sh index 7be3e63fd..8090c2ecf 100755 --- a/scripts/get.sh +++ b/scripts/get.sh @@ -31,10 +31,10 @@ fi remote_get_content() { if curl --version >/dev/null 2>&1 then - curl -fsSL "$1" + curl -fSL "$1" elif wget --version >/dev/null 2>&1 then - wget -q "$1" -O - + wget "$1" -O - fi } @@ -53,12 +53,18 @@ fi # below is installation # print a LOGO! -echo ' _ ' -echo ' __ ___ __ __ __ _| | ______ ' -echo ' \ \/ / | \/ |/ _ | |/ / __ \ ' -echo ' > < | \__/ | /_| | < ___/ ' -echo ' /_/\_\_|_| |_|\__ \|_|\_\____| getter ' -echo ' ' +echo 'xmake, A cross-platform build utility based on Lua. ' +echo 'Copyright (C) 2015-2020 Ruki Wang, tboox.org, xmake.io' +echo ' _ ' +echo ' __ ___ __ __ __ _| | ______ ' +echo ' \ \/ / | \/ |/ _ | |/ / __ \ ' +echo ' > < | \__/ | /_| | < ___/ ' +echo ' /_/\_\_|_| |_|\__ \|_|\_\____| ' +echo ' by ruki, tboox.org ' +echo ' ' +echo ' 👉 Manual: https://xmake.io/#/getting_started ' +echo ' 🙏 Donate: https://xmake.io/#/sponsor ' +echo ' ' my_exit(){ rv=$? @@ -130,7 +136,9 @@ elif [ 'x__run__' = "x$branch" ]; then pack=gz fi mkdir -p $projectdir - remote_get_content "https://github.com/$mirror/xmake/releases/download/$version/xmake-$version.$pack.run" > $projectdir/xmake.run + runfile_url="https://github.com/$mirror/xmake/releases/download/$version/xmake-$version.$pack.run" + echo "downloading $runfile_url .." + remote_get_content "$runfile_url" > $projectdir/xmake.run sh $projectdir/xmake.run --noexec --target $projectdir else if [ x != "x$2" ]; then |
