From e4967160189fa53f041cc50f6e9492f3aef0116d Mon Sep 17 00:00:00 2001 From: clowwindy Date: Sun, 25 Jan 2015 19:23:25 +0800 Subject: [PATCH] fix release script --- packaging/release.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packaging/release.sh b/packaging/release.sh index 4af018c..8958ecf 100755 --- a/packaging/release.sh +++ b/packaging/release.sh @@ -12,9 +12,9 @@ git push origin $1 ./autogen.sh && ./configure && make dist API_JSON=$(printf '{"tag_name": "%s","target_commitish": "master","name": "%s","body": "","draft": false,"prerelease": false}' $VERSION $VERSION) -ID=`curl -v --data "$API_JSON" https://api.github.com/repos/clowwindy/ChinaDNS/releases?access_token=$GITHUB_TOKEN | python -c 'import json,sys;print json.load(sys.stdin)["id"]'` +ID=`curl -L -v --data "$API_JSON" https://api.github.com/repos/clowwindy/ChinaDNS/releases?access_token=$GITHUB_TOKEN | python -c 'import json,sys;d = json.load(sys.stdin);print >>sys.stderr, d;print d["id"]'` -curl -v -H "Content-Type: application/x-tar" \ +curl -v -L -H "Content-Type: application/x-tar" \ -H "Authorization: token $GITHUB_TOKEN" \ --data-binary "@chinadns-$VERSION.tar.gz" \ https://uploads.github.com/repos/clowwindy/ChinaDNS/releases/$ID/assets?name=chinadns-$VERSION.tar.gz