Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
module.exports = ({ cliPkg, cliPath, workflowInstaller }) => {
//-- Initialize
util.initCli();
//-- Don't you dare sudo me
if (cli.isRoot()) {
terminal.dontSudoMe();
//-- Initialize CLI
} else {
util.workflowInstaller = workflowInstaller;
const cliBin = ` cli${chalk.yellow('@')}${cliPkg.version} ${cliPath}`;
const workflowBin = `workflow${chalk.yellow('@')}${env.workflowPkg.version} ${paths.workflow.root}`;
cli.tasksRouter(meow({
pkg: cliPkg,
description: `${env.logo} ${env.workflowPkg.definition}`,
help: `${cli.fullUsage}\n${cliBin}\n${workflowBin}`
}));
}