{"size": 568, "ext": "js", "max_stars_repo_path": "src/modules/console.js", "max_stars_repo_name": "javimosch/wrapkend-docker-worker", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "src/modules/console.js", "max_issues_repo_name": "javimosch/wrapkend-docker-worker", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "src/modules/console.js", "max_forks_repo_name": "javimosch/wrapkend-docker-worker", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 21.037037037, "max_line_length": 53, "alphanum_fraction": 0.5774647887}
//require('path').basename(__filename);
module.exports = {
	create: (file) => {
		var console = require('log-driver')({
			level: process.env.LOGGER_LEVEL || "trace",
			format: function() {
				var args = Array.prototype.slice.call(arguments);
				var level = args[0]
				args.splice(0, 1)
				args = args.map(arg=>{
					if(typeof arg == 'object'){
						return JSON.stringify(arg)
					}else{
						return arg
					}
				})
				return JSON.stringify({
					file,
					level,
					message: args
				});
			}
		});
		console.log = console.trace
		return console;
	}
}