log in console, npm run rmlog
This commit is contained in:
parent
7438a77236
commit
b83cd626c3
@ -7,7 +7,8 @@
|
||||
"build": "./node_modules/.bin/babel src --presets=env --plugins=add-module-exports --out-dir dist",
|
||||
"debug": "node --inspect=9229 dist/bot.js",
|
||||
"start": "npm run build && node dist/bot.js",
|
||||
"inspect": "npm run build && node --inspect=9229 dist/bot.js"
|
||||
"inspect": "npm run build && node --inspect=9229 dist/bot.js",
|
||||
"rmlog": "rm logs/*.log"
|
||||
},
|
||||
"author": "Flummi & jkhsjdhjs",
|
||||
"license": "WTFPL",
|
||||
|
@ -244,7 +244,7 @@ module.exports = irc;
|
||||
util.inherits(irc, EventEmitter);
|
||||
|
||||
function parsePrefix(prefix) {
|
||||
let usertmp = prefix.split("!");
|
||||
let usertmp = prefix.replace(/^:/, "").split("!");
|
||||
let hosttmp = usertmp[1].split("@");
|
||||
return {
|
||||
nick: usertmp[0],
|
||||
|
@ -9,9 +9,12 @@ const logger = new (winston.Logger)({
|
||||
}),
|
||||
new (winston.transports.File)({
|
||||
name: "info-file",
|
||||
filename: `${__dirname}/../../logs/${~~(Date.now() / 1000)}.log`,
|
||||
filename: `${__dirname}/../../logs/${~~(Date.now() / 1000)}_info.log`,
|
||||
level: "info"
|
||||
}),
|
||||
new (winston.transports.Console)({
|
||||
level: "info"
|
||||
})
|
||||
]
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user