protected $options =
[ '--force' => 'Force delete of all logs files without prompting.',
];
/**
* Actually execute a command.
*/
public function run(array
$params) { $force =
array_key_exists('force',
$params) || CLI::
getOption('force'
);
if (!
$force && CLI::
prompt('Are you sure you want to delete the logs?',
['n', 'y'
]) === 'n'
) { // @codeCoverageIgnoreStart
CLI::
error('Deleting logs aborted.', 'light_gray', 'red'
);
CLI::
error('If you want, use the "-force" option to force delete all log files.', 'light_gray', 'red'
);
CLI::
newLine();
return;
// @codeCoverageIgnoreEnd
} helper('filesystem'
);