From b6608ca3e43b9226dec52c44b6a12654c699f990 Mon Sep 17 00:00:00 2001 From: Timothy Stewart Date: Mon, 25 Mar 2024 13:21:32 -0500 Subject: [PATCH] fix(script): fixed yq --- .github/download-boxes.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/download-boxes.sh b/.github/download-boxes.sh index c426668..68ac19b 100755 --- a/.github/download-boxes.sh +++ b/.github/download-boxes.sh @@ -9,8 +9,15 @@ set -euo pipefail GIT_ROOT=$(git rev-parse --show-toplevel) PROVIDER=virtualbox +# requires yq 3 +yq --version + # Read all boxes for all platforms from the "molecule.yml" files -all_boxes=$(yq e 'map(.platforms[].box) | select(type == "string") | unique | join("\n")' "${GIT_ROOT}"/molecule/*/molecule.yml) +all_boxes=$(cat "${GIT_ROOT}"/molecule/*/molecule.yml | + yq -r '.platforms[].box' | # Read the "box" property of each node under "platforms" + grep --invert-match --regexp=--- | # Filter out file separators + sort | + uniq) # Read the boxes that are currently present on the system (for the current provider) present_boxes=$(