Fixed status reporting. 'tr' command wasn't doing any replacement

pull/10469/head
Cruz Monrreal II 2019-04-11 10:50:21 -05:00 committed by adbridge
parent a4b59fe119
commit dc4aa42e86
1 changed files with 3 additions and 3 deletions

View File

@ -32,7 +32,7 @@ die() { echo -e "E: ${1}" 1>&2; exit "${2:-1}"; }
#
set_status()
{
local job_name=${NAME}
local job_name="${NAME}"
local payload=""
payload=$(<<< "
@ -41,10 +41,10 @@ set_status()
'description': '${2}',
'context': 'travis-ci/${job_name}',
'target_url': 'https://travis-ci.org/${TRAVIS_REPO_SLUG}/jobs/${TRAVIS_JOB_ID}'
}" tr '"' '"')
}" tr "'" '"')
curl --silent --output /dev/null --user "${MBED_BOT}" --request POST \
"https://api.github.com/repos/${TRAVIS_REPO_SLUG}/statuses/${TRAVIS_PULL_REQUEST_SHA:-$TRAVIS_COMMIT}" \
"https://api.github.com/repos/${TRAVIS_REPO_SLUG}/statuses/${TRAVIS_PULL_REQUEST_SHA:-${TRAVIS_COMMIT}}" \
--data @- <<< "${payload}"
}