Skip to content

Commit 96bdd2e

Browse files
committed
CXX-3008 replace invalid multiple Bash herestrings with output files (#1155)
1 parent 57a3c2d commit 96bdd2e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

.evergreen/check-augmented-sbom.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,11 @@ podman run \
4343

4444
echo "Comparing Augmented SBOM..."
4545

46-
old_json="$(jq -S '.' ./etc/augmented.sbom.json)"
47-
new_json="$(jq -S '.' ./etc/augmented.sbom.json.new)"
46+
jq -S '.' ./etc/augmented.sbom.json >|old.json
47+
jq -S '.' ./etc/augmented.sbom.json.new >|new.json
4848

4949
# Allow task to upload the augmented SBOM despite failed diff.
50-
if ! diff -sty --left-column -W 200 <<<"${old_json:?}" <<<"${new_json:?}" >|diff.txt; then
50+
if ! diff -sty --left-column -W 200 old.json new.json >|diff.txt; then
5151
declare status
5252
status='{"status":"failed", "type":"test", "should_continue":true, "desc":"detected significant changes in Augmented SBOM"}'
5353
curl -sS -d "${status:?}" -H "Content-Type: application/json" -X POST localhost:2285/task_status || true

0 commit comments

Comments
 (0)