From: Tim Johnson Date: Tue, 4 Feb 2020 22:37:32 +0000 (-0800) Subject: Redirect error to /dev/null X-Git-Tag: v0.51.0~5 X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F35%2F63035%2F1;hp=f528b2b0b8a4a7a7cb48cf401192c6a52f0926d0;p=releng%2Fglobal-jjb.git Redirect error to /dev/null Change-Id: I5e02875c033b8bda4c293b9b3842f26f3ca6133a Signed-off-by: Tim Johnson --- diff --git a/shell/job-cost.sh b/shell/job-cost.sh index 34ab5e73..769b972a 100644 --- a/shell/job-cost.sh +++ b/shell/job-cost.sh @@ -59,7 +59,7 @@ url="https://pricing.vexxhost.net/v1/pricing/$instance_type/cost?seconds=$uptime json_block=$(curl -s "$url") # check if JSON returned and can be parsed -if jq <<< "$json_block"; then +if jq <<< "$json_block" > /dev/null 2>&1; then cost=$(jq .cost <<< "$json_block") resource=$(jq .resource <<< "$json_block" | tr -d '"') else