Skip to content

Commit a9d6ecd

Browse files
Make examples:build dynamically discover all examples
Replace hardcoded workspace list with find + xargs to automatically build all examples in parallel. New examples are picked up without manual script updates. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
1 parent 79fa100 commit a9d6ecd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
"build": "bun build.bun.ts",
3030
"build:all": "npm run build && npm run examples:build",
3131
"test": "bun test",
32-
"examples:build": "concurrently --kill-others-on-fail 'npm run --workspace=examples/basic-host build' 'npm run --workspace=examples/basic-server-react build' 'npm run --workspace=examples/basic-server-vanillajs build'",
32+
"examples:build": "find examples -maxdepth 1 -mindepth 1 -type d -exec printf '%s\\0' 'npm run --workspace={} build' ';' | xargs -0 concurrently --kill-others-on-fail",
3333
"examples:start": "NODE_ENV=development npm run build && concurrently 'npm run examples:start:basic-host' 'npm run examples:start:basic-server-react'",
3434
"examples:start:basic-host": "npm run --workspace=examples/basic-host start",
3535
"examples:start:basic-server-react": "npm run --workspace=examples/basic-server-react start",

0 commit comments

Comments
 (0)