From fcc4e63d2e3100c8555ae081abf9e6f94e80881d Mon Sep 17 00:00:00 2001 From: warman Date: Fri, 5 Apr 2024 12:45:33 -0400 Subject: [PATCH] chore: deno fmt --- src/index.ts | 10 +++++----- src/lib/utils.ts | 4 +++- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/src/index.ts b/src/index.ts index 481588b..28b738f 100644 --- a/src/index.ts +++ b/src/index.ts @@ -36,7 +36,7 @@ await new Command() if (script.startsWith('file://')) { script = import.meta.resolve(script) } else { - script = path.toFileUrl(path.resolve(script)).toString() + script = path.toFileUrl(path.resolve(script)).toString() } const { config }: { main: TriggerFn; config: TriggerConfig } = await import(script) @@ -47,7 +47,7 @@ await new Command() // We want to run this cli as the entry point const cliPath = path.fromFileUrl(import.meta.url) const triggerCommand = `${denoBinary} run -A ${cliPath} exec ${script} ${config.args.join(' ')}` - + // Create a trigger for each type and path const newTriggers: P4Trigger[] = [] config.type.map((type) => { @@ -74,7 +74,7 @@ await new Command() if (script.startsWith('file://')) { script = import.meta.resolve(script) } else { - script = path.toFileUrl(path.resolve(script)).toString() + script = path.toFileUrl(path.resolve(script)).toString() } const { config }: { main: TriggerFn; config: TriggerConfig } = await import(script) @@ -90,7 +90,7 @@ await new Command() // We want to run this cli as the entry point const cliPath = path.fromFileUrl(import.meta.url) const triggerCommand = `${denoBinary} run -A ${cliPath} exec ${script} ${config.args.join(' ')}` - + // Create a trigger for each type and path const newTriggers: P4Trigger[] = [] config.type.map((type) => { @@ -135,7 +135,7 @@ await new Command() if (script.startsWith('file://')) { script = import.meta.resolve(script) } else { - script = path.toFileUrl(path.resolve(script)).toString() + script = path.toFileUrl(path.resolve(script)).toString() } const { main, config }: { main: TriggerFn; config: TriggerConfig } = await import(script) diff --git a/src/lib/utils.ts b/src/lib/utils.ts index 8021b1d..0068c3d 100644 --- a/src/lib/utils.ts +++ b/src/lib/utils.ts @@ -89,7 +89,9 @@ export function renderTriggerTable(triggers: P4Trigger[]): void { new Table() .header(Row.from(['Index', 'Name', 'Type', 'Path', 'Command']).border()) .body( - triggers.map((trigger) => new Row(trigger.index.toString(), trigger.name, trigger.type, trigger.path, trigger.command)), + triggers.map((trigger) => + new Row(trigger.index.toString(), trigger.name, trigger.type, trigger.path, trigger.command) + ), ) .border(true) .render()