refactor: add a quick and dirty shell script to build examples
authorJérôme Benoit <jerome.benoit@piment-noir.org>
Fri, 1 Sep 2023 20:36:06 +0000 (22:36 +0200)
committerJérôme Benoit <jerome.benoit@piment-noir.org>
Fri, 1 Sep 2023 20:36:06 +0000 (22:36 +0200)
Signed-off-by: Jérôme Benoit <jerome.benoit@piment-noir.org>
examples/typescript/build.sh [new file with mode: 0755]

diff --git a/examples/typescript/build.sh b/examples/typescript/build.sh
new file mode 100755 (executable)
index 0000000..1e8ef87
--- /dev/null
@@ -0,0 +1,15 @@
+#!/usr/bin/env bash
+
+set -e
+
+examples=$(find . -name "package.json" -maxdepth 3 -exec dirname {} \;)
+
+for example in $examples
+do
+  echo -e "Building $example"
+  cd $example
+  pnpm install
+  pnpm build
+  cd -
+done
+