UNPKG

620 BJavaScriptView Raw
1// #!/usr/bin/env node
2
3'use strict';
4
5function isTrue(value) {
6 return !!value && value !== '0' && value !== 'false';
7}
8
9let envDisable = isTrue(process.env.DISABLE_OPENCOLLECTIVE) || isTrue(process.env.CI);
10let logLevel = process.env.npm_config_loglevel;
11let logLevelDisplay = ['silent', 'error', 'warn'].indexOf(logLevel) > -1;
12
13if (!envDisable && !logLevelDisplay) {
14 console.log(`Thank you for using \x1b[32m@leanup/cli\x1b[37m.
15--------------------------------
16Create a ticket if you have ideas or advices on how we can further simplify this tool: \x1b[34mhttps://github.com/leanupjs/leanup/issues\x1b[37m
17`);
18}