From 667995fd9e8c98a6b3174d87f447360399283661 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mislav=20Marohni=C4=87?= Date: Sun, 10 Jan 2016 20:28:27 +0100 Subject: [PATCH] Print the port being used when starting `script/server` --- script/server | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/script/server b/script/server index b41c6b85..b1988a0d 100755 --- a/script/server +++ b/script/server @@ -123,7 +123,7 @@ var types = { txt: 'text/plain' }; -http.createServer(function(req, res) { +server = http.createServer(function(req, res) { var pathname = url.parse(req.url).pathname; var route = routes[pathname]; if (route) { @@ -140,4 +140,8 @@ http.createServer(function(req, res) { } }); } -}).listen(port); +}); + +console.warn("Started test server on localhost:" + port); +server.listen(port); +