Created
February 18, 2020 13:30
-
-
Save qzed/8fd25f822c2541078cc3e55315863660 to your computer and use it in GitHub Desktop.
Trigger repository_dispatch event for action on github repository.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/bash | |
# Usage: ./trigger_dispatch.sh <org>/<repo> <user> <user-access-token> | |
repo="${1}" | |
user="${2}" | |
token="${3}" | |
curl --verbose -X POST -u "${user}:${token}" \ | |
-H "Content-Type: application/json" \ | |
"https://api.github.com/repos/${repo}/dispatches" \ | |
--data '{"event_type": "repository_dispatch"}' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment