From 9e28903d4b19a3eb8527c18f4f366439d5c3faa4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kalle=20Ahlstr=C3=B6m?= Date: Sun, 5 Jan 2025 13:14:49 +0200 Subject: [PATCH] fix: add fallback to node for generate_seeding_data script --- scripts/generate_seeding_data.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/generate_seeding_data.sh b/scripts/generate_seeding_data.sh index b5d96196..31e27239 100755 --- a/scripts/generate_seeding_data.sh +++ b/scripts/generate_seeding_data.sh @@ -32,4 +32,9 @@ for COLLECTION_NAME in $COLLECTIONS; do fi done echo "cleaning up excess versions from versioned collections..." -bun run scripts/remove_excess_versions.ts +if ! [ -x "$(command -v bun)" ]; then + echo "bun is not installed, running with node with --experimental-strip-types..." + node --experimental-strip-types apps/cms/src/scripts/import-uploads.ts +else + bun run scripts/remove_excess_versions.ts +fi