Skip to content

Commit

Permalink
Make release using valid json
Browse files Browse the repository at this point in the history
Properly balancing json and bash's quoting requirements with
variables is a little tricky. Escaping the "s instead of using '
appears to be the solution.
  • Loading branch information
ethanwhite committed Jul 23, 2017
1 parent 64d8caa commit 30e75c6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion update_repo.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@ if [ "$last_commit_date" != "$current_date" ]; then
# Create a new release to trigger automated Zenodo archiving
git tag $current_date
git push --quiet deploy --tags > /dev/null 2>&1
curl -v -i -X POST -H "Content-Type:application/json" -H "Authorization: token $GITHUB_RELEASE_TOKEN" https://api.github.com/repos/weecology/portalPredictions/releases -d "{'tag_name':$current_date}"
curl -v -i -X POST -H "Content-Type:application/json" -H "Authorization: token $GITHUB_RELEASE_TOKEN" https://api.github.com/repos/weecology/portalPredictions/releases -d "{\"tag_name\":\"$current_date\"}"
fi

0 comments on commit 30e75c6

Please sign in to comment.