Fixed CLI showing undefined when not specifying a trigger-url flag

This commit is contained in:
Eric Allam
2023-06-27 13:00:06 +01:00
parent 7b6647cfd4
commit 62f94206bb
2 changed files with 8 additions and 1 deletions
+5
View File
@@ -0,0 +1,5 @@
---
"@trigger.dev/init": patch
---
Fixed CLI showing undefined when not specifying a trigger-url flag
+3 -1
View File
@@ -19,10 +19,12 @@ const main = async () => {
if (cliOptions.flags.triggerUrl === DEFAULT_TRIGGER_URL) {
logger.info(`✨ Initializing project in Trigger.dev Cloud`);
} else {
} else if (typeof cliOptions.flags.triggerUrl === "string") {
logger.info(
`✨ Initializing project using Trigger.dev at ${cliOptions.flags.triggerUrl}`
);
} else {
logger.info(`✨ Initializing Trigger.dev in project`);
}
const resolvedPath = resolvePath(cliOptions.flags.projectPath);