Skip to content

Commit 329a893

Browse files
committed
test
1 parent 148f9b6 commit 329a893

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

.github/workflows/validate-new-plugin-metadata.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,11 @@ jobs:
9494
9595
# Handle arrays of URLs (e.g., screenshots)
9696
# Check if the field is an array using yq length check
97-
is_array=$(echo "$metadata" | yq -r ".${field} | length")
97+
local field_type
98+
field_type=$(echo "$metadata" | yq -r ".${field} | type")
99+
echo "Field type: $field_type"
98100
99-
if [[ "$is_array" =~ ^[0-9]+$ && "$is_array" -gt 0 ]]; then
101+
if [[ "$field_type" == "array" ]]; then
100102
# Iterate properly over array elements
101103
for url in $(echo "$metadata" | yq -r ".$field[]" || true); do
102104
if [[ -z "$url" ]]; then # Skip empty values inside arrays

plugins/new_plugin/plugin_metadata.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,7 @@ detailed_description: "Plugin's detailed description"
1010

1111
# Media & Assets
1212
plugin_logo_url: ""
13-
screenshots:
14-
- ""
15-
- ""
13+
screenshots: [ "", ""]
1614
demo_video_url: ""
1715
documentation_url: ""
1816
changelog_url: ""

0 commit comments

Comments
 (0)