diff --git a/cli/deno.lock b/cli/deno.lock index 365b7d0e79..f91c671d29 100644 --- a/cli/deno.lock +++ b/cli/deno.lock @@ -53,6 +53,7 @@ "jsr:@windmill-labs/cliffy-internal@1.0.0-rc.5": "jsr:@windmill-labs/cliffy-internal@1.0.0-rc.5", "jsr:@windmill-labs/cliffy-keycode@1.0.0-rc.5": "jsr:@windmill-labs/cliffy-keycode@1.0.0-rc.5", "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.5": "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.5", + "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.6": "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.6", "jsr:@windmill-labs/cliffy-prompt@^1.0.0-rc.5": "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.5", "jsr:@windmill-labs/cliffy-table@1.0.0-rc.5": "jsr:@windmill-labs/cliffy-table@1.0.0-rc.5", "jsr:@windmill-labs/cliffy-table@^1.0.0-rc.5": "jsr:@windmill-labs/cliffy-table@1.0.0-rc.5", @@ -259,6 +260,19 @@ "jsr:@windmill-labs/cliffy-keycode@1.0.0-rc.5" ] }, + "@windmill-labs/cliffy-prompt@1.0.0-rc.6": { + "integrity": "ffe09bee0e1e07bc12b2147be509d10b47eb6a36cbfea80fc206b4ae86693205", + "dependencies": [ + "jsr:@std/assert@1.0.0-rc.2", + "jsr:@std/fmt@~0.225.4", + "jsr:@std/io@~0.224.2", + "jsr:@std/path@1.0.0-rc.2", + "jsr:@std/text@1.0.0-rc.1", + "jsr:@windmill-labs/cliffy-ansi@1.0.0-rc.5", + "jsr:@windmill-labs/cliffy-internal@1.0.0-rc.5", + "jsr:@windmill-labs/cliffy-keycode@1.0.0-rc.5" + ] + }, "@windmill-labs/cliffy-table@1.0.0-rc.5": { "integrity": "5f26cb6ccbc2fbf1b1f79f9062d166e32e11d34398c0deac7e6f9d8378970546", "dependencies": [ diff --git a/cli/deps.ts b/cli/deps.ts index fc862a65fd..b4b018e884 100644 --- a/cli/deps.ts +++ b/cli/deps.ts @@ -5,10 +5,10 @@ export * from "npm:windmill-client@1.364.0"; export { Command } from "jsr:@windmill-labs/cliffy-command@1.0.0-rc.5"; export { Table } from "jsr:@windmill-labs/cliffy-table@1.0.0-rc.5"; export { colors } from "jsr:@windmill-labs/cliffy-ansi@1.0.0-rc.5/colors"; -export { Secret } from "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.5/secret"; -export { Select } from "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.5/select"; -export { Confirm } from "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.5/confirm"; -export { Input } from "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.5/input"; +export { Secret } from "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.6/secret"; +export { Select } from "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.6/select"; +export { Confirm } from "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.6/confirm"; +export { Input } from "jsr:@windmill-labs/cliffy-prompt@1.0.0-rc.6/input"; export { UpgradeCommand } from "jsr:@windmill-labs/cliffy-command@1.0.0-rc.5/upgrade"; export { NpmProvider } from "jsr:@windmill-labs/cliffy-command@1.0.0-rc.5/upgrade/provider/npm"; export { Provider } from "jsr:@windmill-labs/cliffy-command@1.0.0-rc.5/upgrade"; diff --git a/cli/dev.ts b/cli/dev.ts index d9dc1ab3f8..2da25ec4ac 100644 --- a/cli/dev.ts +++ b/cli/dev.ts @@ -124,7 +124,11 @@ async function dev(opts: GlobalOptions & SyncOptions) { console.log(`Go to ${url}`); try { - open.openApp(open.apps.browser, { arguments: [url] }); + open.openApp(open.apps.browser, { arguments: [url] }).catch((error) => { + console.error( + `Failed to open browser, please navigate to ${url}, error: ${error}` + ); + }); console.log("Opened browser for you"); } catch (error) { console.error( diff --git a/cli/login.ts b/cli/login.ts index 0d9d65a578..3476007301 100644 --- a/cli/login.ts +++ b/cli/login.ts @@ -27,7 +27,6 @@ export async function loginInteractive(remote: string) { } else { token = await Secret.prompt("Enter your token"); } - return token; } @@ -105,7 +104,11 @@ export async function browserLogin( log.info(`Login by going to ${url}`); try { - open.openApp(open.apps.browser, { arguments: [url] }); + open.openApp(open.apps.browser, { arguments: [url] }).catch((error) => { + console.error( + `Failed to open browser, please navigate to ${url}, error: ${error}` + ); + }); log.info("Opened browser for you"); } catch (error) { diff --git a/cli/main.ts b/cli/main.ts index 056cb2d7f2..8a4d8f561c 100644 --- a/cli/main.ts +++ b/cli/main.ts @@ -56,9 +56,9 @@ export { // } // }); -export const VERSION = "1.393.4"; +export const VERSION = "1.393.6"; -let command: any = new Command() +const command = new Command() .name("wmill") .action(() => log.info(`Welcome to Windmill CLI ${VERSION}. Use -h for help.`)