ci: filter build-examples to directories with build.zig.zon
The dynamic example directory discovery added in bb3b3ba included
all subdirectories under example/, but some (wasm-key-encode,
wasm-sgr) are pure HTML examples with no build.zig.zon. Running
zig build in those directories falls back to the root build.zig
and attempts a full GTK binary build, which fails on CI.
Filter the listing to only include directories that contain a
build.zig.zon file so non-Zig examples are excluded from the
build matrix.
pull/11609/head
parent
15b8976d64
commit
ceef8065b0
|
|
@ -179,7 +179,7 @@ jobs:
|
|||
- id: list
|
||||
name: List example directories
|
||||
run: |
|
||||
dirs=$(ls -d example/*/ | xargs -n1 basename | jq -R -s -c 'split("\n") | map(select(. != ""))')
|
||||
dirs=$(ls example/*/build.zig.zon 2>/dev/null | xargs -n1 dirname | xargs -n1 basename | jq -R -s -c 'split("\n") | map(select(. != ""))')
|
||||
echo "$dirs" | jq .
|
||||
echo "dirs=$dirs" >> "$GITHUB_OUTPUT"
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue