Skip to content

Commit

Permalink
Added script for triggering the build
Browse files Browse the repository at this point in the history
  • Loading branch information
pmconrad committed Nov 28, 2019
1 parent 95b9f1e commit 1784b1d
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
18 changes: 18 additions & 0 deletions .github/trigger-workflow.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/bin/sh

if [ "$#" != 1 ]; then
echo "Usage: $0 <core-version>" 1>&2
exit 1
fi

if [ ! -r "$(dirname $0)/token" ]; then
echo "Create an API token on github with the 'deployment' privilege and" 1>&2
echo "put it into '$(dirname $0)/token'." 1>&2
exit 1
fi

curl -H "Authorization: token $(head -c 40 "$(dirname $0)/token")" \
-H "Content-Type: application/json" \
--data '{"ref":"action-test","required_contexts":[],"payload":{"coreversion":"'"$1"'"}}' \
https://api.github.com/repos/pmconrad/bitshares-gitian/deployments

1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
/docker
/var
.github/token

0 comments on commit 1784b1d

Please sign in to comment.