Shuo/index.js

12 lines
239 B
JavaScript
Raw Normal View History

2014-03-07 21:24:02 +00:00
var argv = require("commander")
2014-03-04 16:31:52 +00:00
.option("-p, --port <n>", "port to use", parseInt)
2014-03-06 15:11:25 +00:00
.parse(process.argv);
2014-03-04 16:31:52 +00:00
2014-03-06 22:36:56 +00:00
PORT = 80; // Default port
2014-03-04 16:31:52 +00:00
if (argv.port) {
PORT = argv.port;
}
2014-03-07 21:24:02 +00:00
var server =
new (require("./lib/server.js"))()
2014-03-11 23:14:26 +00:00
.listen(PORT);