Update push_json_to_pocketbase.yml

This commit is contained in:
CanbiZ (MickLesk)
2026-04-15 13:16:25 +02:00
parent c4cb48f0c7
commit 60b9d22c77

View File

@@ -30,6 +30,18 @@ jobs:
if [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
script_slug="${{ github.event.inputs.script_slug }}"
if [[ "$script_slug" == "*" || "$script_slug" == "all" ]]; then
count=0
for f in json/*.json; do
[[ -f "$f" ]] || continue
jq -e '.slug' "$f" >/dev/null 2>&1 || continue
echo "$f" >> changed_app_jsons.txt
count=$((count + 1))
done
echo "count=${count}" >> "$GITHUB_OUTPUT"
echo "Queued ${count} JSON files for push."
exit 0
fi
file="json/${script_slug}.json"
if [[ ! -f "$file" ]]; then
echo "No JSON file at $file."