From 3b7f7b629bc7b290b83745a5f5b0065afbf084b0 Mon Sep 17 00:00:00 2001 From: fennecdjay Date: Tue, 28 Feb 2023 13:06:06 +0100 Subject: [PATCH] :bug: embed script --- scripts/embed.bash | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/scripts/embed.bash b/scripts/embed.bash index c5ce77f1..915167da 100644 --- a/scripts/embed.bash +++ b/scripts/embed.bash @@ -168,15 +168,16 @@ samplerate=$(jq -rc '.samplerate' <<< "$audio") args=$(jq -rc '.args' <<< "$json") -array_is_ok "$args" && { +{ count=0 config "CFLAGS += -DGWION_CONFIG_ARGS" echo "static const char *config_argv[] = {" - jq -rc '.[]' <<< "$args" | - while read -r arg - do - echo " \"$arg\", " - done + array_is_ok "$args" && { + jq -rc '.[]' <<< "$args" | + while read -r arg + do echo " \"$arg\", " + done + } echo "};" count=$((count+1)) echo "static const int config_argc = $count;" -- 2.43.0