From 017190be27d1b03b1236fd8d41e67e32ddc1ffc8 Mon Sep 17 00:00:00 2001 From: Ruben Fiszel Date: Sat, 9 Mar 2024 17:05:57 +0100 Subject: [PATCH] fix(cli): warn to switch to bun in the CLI --- cli/conf.ts | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/cli/conf.ts b/cli/conf.ts index c85e065667..89f88cbbb2 100644 --- a/cli/conf.ts +++ b/cli/conf.ts @@ -1,4 +1,4 @@ -import { yamlParse } from "./deps.ts"; +import { log, yamlParse } from "./deps.ts"; export interface SyncOptions { stateful?: boolean; @@ -26,9 +26,16 @@ export async function readConfigFile(): Promise { const conf = yamlParse( await Deno.readTextFile("wmill.yaml") ) as SyncOptions; - + if (conf.defaultTs) { + log.warning( + 'No defaultTs defined in your wmill.yaml, using deno as default typescript language. Set defaultTs in wmill.yaml to "bun" to switch (https://www.windmill.dev/docs/advanced/cli/sync#wmillyaml)' + ); + } return typeof conf == "object" ? conf : ({} as SyncOptions); } catch (e) { + log.warning( + 'No wmill.yaml found, using deno as default typescript language. Create a wmill.yaml with a defaultTs set to "bun" to switch (https://www.windmill.dev/docs/advanced/cli/sync#wmillyaml)' + ); return {}; } }