From 7defba55eb964be64f08f9eac46766f48aab329d Mon Sep 17 00:00:00 2001 From: Mattias Erming Date: Mon, 15 Sep 2014 12:50:57 -0700 Subject: [PATCH] Added '-v, --version' option --- src/command-line/index.js | 2 ++ src/command-line/start.js | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/command-line/index.js b/src/command-line/index.js index a281f43b..5001f30a 100644 --- a/src/command-line/index.js +++ b/src/command-line/index.js @@ -1,6 +1,8 @@ var program = require("commander"); var pkg = require("../../package.json"); +program.version(pkg.version, "-v, --version"); + require("./start"); require("./config"); require("./list"); diff --git a/src/command-line/start.js b/src/command-line/start.js index e8ba0e19..061dbbb9 100644 --- a/src/command-line/start.js +++ b/src/command-line/start.js @@ -4,10 +4,10 @@ var program = require("commander"); var shout = require("../server"); program - .option("-h, --host ", "host") + .option("-H, --host ", "host") .option("-p, --port ", "port") - .option(" --public") - .option(" --private") + .option(" --public", "mode") + .option(" --private", "mode") .command("start") .description("Start the server") .action(function() {