diff --git a/cli/src/services/formatters/hook-runner.ts b/cli/src/services/formatters/hook-runner.ts index fabb2d3d..27f24ba4 100644 --- a/cli/src/services/formatters/hook-runner.ts +++ b/cli/src/services/formatters/hook-runner.ts @@ -7,7 +7,7 @@ const capitalizeFirstLetter = (str: string) => export default class HookRunnerFomatter { log(name: string, commands: string[]) { - const operation = capitalizeFirstLetter(decamelize(name, { separator: ' ' })); + const operation = capitalizeFirstLetter(decamelize(name, {separator: ' '})); console.log(chalk.yellow('➤ '), chalk.bold(chalk.yellow(`${operation}:`))); commands.forEach((command) => { console.log(' ', chalk.yellow(command)); diff --git a/cli/src/services/hook-runner.ts b/cli/src/services/hook-runner.ts index 39835b8d..9b278f83 100644 --- a/cli/src/services/hook-runner.ts +++ b/cli/src/services/hook-runner.ts @@ -1,11 +1,11 @@ // Vendor -import { execSync } from 'child_process'; +import {execSync} from 'child_process'; // Formatters import Formatter from './formatters/hook-runner'; // Types -import { HookConfig, Hooks } from '../types/document-config'; +import {HookConfig, Hooks} from '../types/document-config'; import Document from './document'; export default class HookRunner { @@ -23,13 +23,13 @@ export default class HookRunner { const hooks = this.hooks[name]; if (hooks) { - const formatter = new Formatter() + const formatter = new Formatter(); formatter.log(name, hooks); hooks.forEach((hook) => { try { - const output: string = execSync(hook, { stdio: 'pipe' }).toString(); - formatter.log(hook, [output]) + const output: string = execSync(hook, {stdio: 'pipe'}).toString(); + formatter.log(hook, [output]); } catch (error: any) { formatter.error(hook, [error.stderr.toString()]); process.exit(error.status);