text: const chalk=require("chalk"),SEVERITY={NONE:0,BOLD:1,URL:2,NOTIFY:3,LOW:4,WARN:5,ERROR:6,SUCCESS:7};"true"===process.env.ENABLE_LOGGING&&(console.log=function(){});const formatMessage=(e,a=0)=>{let t;const o=new Date;var l=chalk.black.bgWhite(`CNK-TP | ${o.toLocaleDateString("en-US",{month:"long",day:"numeric",hour:"2-digit",minute:"2-digit",second:"2-digit"})} `);switch(a){case SEVERITY.SUCCESS:t=`${l} ${chalk.green(e)}`;break;case SEVERITY.ERROR:t=`${l} ${chalk.red(e)}`;break;case SEVERITY.WARN:t=`${l} ${chalk.yellow(e)}`;break;case SEVERITY.LOW:t=`${l} ${chalk.magenta(e)}`;break;case SEVERITY.NOTIFY:t=`${l} ${chalk.bold(e)}`;break;case SEVERITY.URL:var c=e.match("(http|https)://(([a-z0-9]|[a-z0-9][a-z0-9-]*[a-z0-9]).)*([a-z0-9]|[a-z0-9][a-z0-9-]*[a-z0-9])(:[0-9]+)?$");e=e.replace(c[0],""),t=`${l} ${e}${chalk.underline.blue(c[0])}`;break;case SEVERITY.BOLD:t=`${l} ${chalk.bold(e)}`;break;case SEVERITY.NONE:default:t=`${l} ${e}`}return t},logFormatted=(e,a=0,t=null)=>{t?console.log(formatMessage(e,a),t):console.log(formatMessage(e,a))};module.exports={SEVERITY:SEVERITY,formatMessage:formatMessage,logFormatted:logFormatted};