--- /dev/null
+---
+fixes:
+ - |
+ Echo error response from RTD without formatting. The script
+ rtd-trigger-build.sh starts a build at ReadTheDocs and parses
+ the response, a small JSON like this:
+
+ {"build_triggered":false,"project":"unicorn","versions":[]}
+
+ This change drops the invocation of jq that attempts to pretty-print
+ the JSON to the log when the build is not triggered, because that
+ call was failing for inexplicable reasons.
# which accompanies this distribution, and is available at
# http://www.eclipse.org/legal/epl-v10.html
##############################################################################
-# Call cURL to trigger a build in RTD via the Generic API
+# Calls cURL to trigger a build in RTD via the Generic API
#
-# Paramters:
+# Parameters:
# RTD_BUILD_URL: The unique build URL for the project.
# Check Admin > Integrations > Generic API incoming webhook.
#
build_triggered=$(echo "$json" | jq -r .build_triggered)
if [ "$build_triggered" != "true" ]; then
- echo "ERROR: Build was not triggered."
- echo "$json" | jq -r
+ echo "ERROR: Build was not triggered, ReadTheDocs response follows:"
+ echo "$json"
exit 1
fi
echo "Build triggered for $GERRIT_PROJECT in ReadTheDocs."
+echo "---> rtd-trigger-build.sh ends"