Skip to content

Commit

Permalink
fix release script
Browse files Browse the repository at this point in the history
  • Loading branch information
clowwindy committed Jan 30, 2015
1 parent d97e8b5 commit e496716
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packaging/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -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

0 comments on commit e496716

Please sign in to comment.