Update dependency prettier to v2.5.1 (#43473)
* Update dependency prettier to v2.5.1 * prettier fixes * chore(toolkit): bump prettier to 2.5.1 * style(eslint): bump grafana config to 2.5.2 in core and toolkit * style(mssql-datasource): fix no-inferrable-types eslint errors Co-authored-by: Renovate Bot <bot@renovateapp.com> Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com> Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
This commit is contained in:
co-authored by
Renovate Bot
Ashley Harrison
Jack Westbrook
parent
3b4e812449
commit
d87cd6f26c
@@ -7,17 +7,19 @@ interface TaskBasicOptions {
|
||||
silent?: boolean;
|
||||
}
|
||||
|
||||
export const execTask = <TOptions>(task: Task<TOptions>) => async (options: TOptions & TaskBasicOptions) => {
|
||||
if (!options.silent) {
|
||||
console.log(chalk.yellow(`Running ${chalk.bold(task.name)} task`));
|
||||
}
|
||||
task.setOptions(options);
|
||||
try {
|
||||
console.group();
|
||||
await task.exec();
|
||||
console.groupEnd();
|
||||
} catch (e) {
|
||||
console.trace(e);
|
||||
process.exit(1);
|
||||
}
|
||||
};
|
||||
export const execTask =
|
||||
<TOptions>(task: Task<TOptions>) =>
|
||||
async (options: TOptions & TaskBasicOptions) => {
|
||||
if (!options.silent) {
|
||||
console.log(chalk.yellow(`Running ${chalk.bold(task.name)} task`));
|
||||
}
|
||||
task.setOptions(options);
|
||||
try {
|
||||
console.group();
|
||||
await task.exec();
|
||||
console.groupEnd();
|
||||
} catch (e) {
|
||||
console.trace(e);
|
||||
process.exit(1);
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user