Skip to content

Commit fc8f28e

Browse files
committed
ci(build): Use jq to produce JSOn without newlines
1 parent b9663b8 commit fc8f28e

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

.github/workflows/reusable_build_image.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@ jobs:
3939
RUNNERS_TYPE: ${{ inputs.runners }}
4040
run: |
4141
if [ "$RUNNERS_TYPE" == "mixed" ]; then
42-
RUNNERS=$(cat .github/workflows/runners/mixed.json)
43-
echo "RUNNERS<<EOF\n$RUNNERS\nEOF" | tee -a "$GITHUB_OUTPUT"
42+
RUNNERS=$(cat .github/workflows/runners/mixed.json | jq --compact-output)
43+
echo "RUNNERS=$RUNNERS" | tee -a "$GITHUB_OUTPUT"
4444
elif [ "$RUNNERS_TYPE" == "ubicloud" ]; then
45-
RUNNERS=$(cat .github/workflows/runners/ubicloud.json)
46-
echo "RUNNERS<<EOF\n$RUNNERS\nEOF" | tee -a "$GITHUB_OUTPUT"
45+
RUNNERS=$(cat .github/workflows/runners/ubicloud.json | jq --compact-output)
46+
echo "RUNNERS=$RUNNERS" | tee -a "$GITHUB_OUTPUT"
4747
else
4848
echo "Invalid runners type, expected 'mixed' or 'ubicloud'"
4949
exit 1

0 commit comments

Comments
 (0)