Files
mono/scripts/ci/util.sh
T
Alexander Köplinger 0ea0f84a0d [bcl] Add API diff targets (#4406)
With these targets we can generate a snapshot of the current
Mono API in C# source code form.

Whenever we make changes, we can rerun this to ensure we didn't
inadvertently change the public API.

It also outputs a diff in html form that we can show on CI.
2017-04-28 20:28:32 +02:00

12 lines
904 B
Bash

#!/bin/bash -e
function report_github_status {
if [ -z "$1" ]; then echo "No status specified. Skipping GitHub manual status report."; return 1; fi;
if [ -z "$2" ]; then echo "No context specified. Skipping GitHub manual status report."; return 1; fi;
if [ -z "$3" ]; then echo "No description specified. Skipping GitHub manual status report."; return 1; fi;
if [ -z "${ghprbActualCommit}" ]; then echo "Not a pull request. Skipping GitHub manual status report."; return 1; fi;
if [ -z "${GITHUB_STATUS_AUTH_TOKEN}" ]; then echo "No auth token specified. Skipping GitHub manual status report."; return 1; fi;
wget -qO- --header "Content-Type: application/json" --post-data "{\"state\": \"$1\", \"context\":\"$2\", \"description\": \"$3\", \"target_url\": \"$4\"}" "https://api.github.com/repos/mono/mono/statuses/${ghprbActualCommit}?access_token=${GITHUB_STATUS_AUTH_TOKEN}"
}