From f2a4123e0bcbbf551ee00c8347d64e54c4cca6ba Mon Sep 17 00:00:00 2001 From: Gerald Pinder Date: Mon, 25 Nov 2024 22:18:21 -0500 Subject: [PATCH] fix: Export get_json_array bash function --- integration-tests/test-repo/files/scripts/example.sh | 4 ++++ scripts/exports.sh | 1 + 2 files changed, 5 insertions(+) diff --git a/integration-tests/test-repo/files/scripts/example.sh b/integration-tests/test-repo/files/scripts/example.sh index fdb2e04..bed8a26 100644 --- a/integration-tests/test-repo/files/scripts/example.sh +++ b/integration-tests/test-repo/files/scripts/example.sh @@ -8,3 +8,7 @@ set -oue pipefail # Your code goes here. echo 'This is an example shell script' echo 'Scripts here will run during build if specified in recipe.yml' + +get_json_arr FILES '.test' '{"test":[1,2,3]}' + +echo $FILES diff --git a/scripts/exports.sh b/scripts/exports.sh index 77d72c4..1376cb3 100644 --- a/scripts/exports.sh +++ b/scripts/exports.sh @@ -68,5 +68,6 @@ export OS_ARCH=$(uname -m) # Export functions for use in sub-shells or sourced scripts export -f get_yaml_array +export -f get_json_array mkdir -p /var/roothome /var/opt /var/lib/alternatives /var/opt /var/usrlocal