From 1dac981191463cfcf8e37a5e82c03ac98dbb6180 Mon Sep 17 00:00:00 2001 From: Rob Arnold Date: Sat, 4 Jun 2011 02:33:12 +0000 Subject: [PATCH] Provide a restart function for the console mode --- bot.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bot.js b/bot.js index 394fb33..3d98904 100644 --- a/bot.js +++ b/bot.js @@ -6,6 +6,10 @@ var mode = 'irc'; if (process.argv.length > 2) mode = process.argv[2]; if (mode === 'console') { + updater.restart = function () { + console.log("It's less awkward if I just exit"); + process.exit() + } // Console channel var consoleChannel = channels.add('', console.log); process.stdin.resume();