Commit 716c0d04 authored by Leif Walsh's avatar Leif Walsh

closes #4 add non-authenticated download method

parent f9163c72
...@@ -96,7 +96,7 @@ function github_download() { ...@@ -96,7 +96,7 @@ function github_download() {
--file $dest.tar.gz --file $dest.tar.gz
if [ $? != 0 ] ; then return; fi if [ $? != 0 ] ; then return; fi
rm -f $dest.tar.gz rm -f $dest.tar.gz
else elif [ $github_use_ssh != 0 ] ; then
tempdir=$(mktemp -d -p $PWD) tempdir=$(mktemp -d -p $PWD)
retry git clone git@github.com:${repo}.git $tempdir retry git clone git@github.com:${repo}.git $tempdir
if [ $? != 0 ] ; then return; fi if [ $? != 0 ] ; then return; fi
...@@ -115,6 +115,17 @@ function github_download() { ...@@ -115,6 +115,17 @@ function github_download() {
--directory $dest --directory $dest
if [ $? != 0 ] ; then return; fi if [ $? != 0 ] ; then return; fi
rm -rf $tempdir rm -rf $tempdir
else
retry curl \
--location https://api.github.com/repos/$repo/tarball/$rev \
--output $dest.tar.gz
tar --extract \
--gzip \
--directory=$dest \
--strip-components=1 \
--file $dest.tar.gz
if [ $? != 0 ] ; then return; fi
rm -f $dest.tar.gz
fi fi
} }
...@@ -636,6 +647,7 @@ system=$(uname -s | tr '[:upper:]' '[:lower:]') ...@@ -636,6 +647,7 @@ system=$(uname -s | tr '[:upper:]' '[:lower:]')
arch=$(uname -m | tr '[:upper:]' '[:lower:]') arch=$(uname -m | tr '[:upper:]' '[:lower:]')
makejobs=$(get_ncpus) makejobs=$(get_ncpus)
github_use_ssh=0
git_tag=HEAD git_tag=HEAD
mysqlbuild= mysqlbuild=
mysql=mysql-5.5.30 mysql=mysql-5.5.30
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment