Lloyd Brookes
10 years ago
3 changed files with 66 additions and 69 deletions
-
69bin/ws.js
-
24lib/cli-options.js
-
8package.json
@ -1,40 +1,30 @@ |
|||||
module.exports = [ |
module.exports = [ |
||||
{ |
{ |
||||
groups: "Server", |
|
||||
options: [ |
|
||||
{ |
|
||||
name: "port", alias: "p", type: Number, defaultOption: true, |
name: "port", alias: "p", type: Number, defaultOption: true, |
||||
description: "Web server port" |
|
||||
|
description: "Web server port", group: "server" |
||||
}, |
}, |
||||
{ |
{ |
||||
name: "log-format", alias: "f", type: String, |
name: "log-format", alias: "f", type: String, |
||||
description: "If a format is supplied an access log is written to stdout. If not, a statistics view is displayed. Use a preset ('none', 'dev','combined', 'short', 'tiny' or 'logstalgia') or supply a custom format (e.g. ':method -> :url')." |
|
||||
|
description: "If a format is supplied an access log is written to stdout. If not, a statistics view is displayed. Use a preset ('none', 'dev','combined', 'short', 'tiny' or 'logstalgia') or supply a custom format (e.g. ':method -> :url').", group: "server" |
||||
}, |
}, |
||||
{ |
{ |
||||
name: "directory", alias: "d", type: String, |
name: "directory", alias: "d", type: String, |
||||
description: "Root directory, defaults to the current directory" |
|
||||
|
description: "Root directory, defaults to the current directory", group: "server" |
||||
}, |
}, |
||||
{ |
{ |
||||
name: "compress", alias: "c", type: Boolean, |
name: "compress", alias: "c", type: Boolean, |
||||
description: "Enables compression" |
|
||||
|
description: "Enables compression", group: "server" |
||||
}, |
}, |
||||
{ |
{ |
||||
name: "refresh-rate", alias: "r", type: Number, |
name: "refresh-rate", alias: "r", type: Number, |
||||
description: "Statistics view refresh rate in ms. Defaults to 500." |
|
||||
} |
|
||||
] |
|
||||
|
description: "Statistics view refresh rate in ms. Defaults to 500.", group: "server" |
||||
}, |
}, |
||||
{ |
{ |
||||
groups: "Misc", |
|
||||
options: [ |
|
||||
{ |
|
||||
name: "help", alias: "h", type: Boolean, |
name: "help", alias: "h", type: Boolean, |
||||
description: "Print these usage instructions" |
|
||||
|
description: "Print these usage instructions", group: "misc" |
||||
}, |
}, |
||||
{ |
{ |
||||
name: "config", type: Boolean, |
name: "config", type: Boolean, |
||||
description: "Print the stored config" |
|
||||
} |
|
||||
] |
|
||||
|
description: "Print the stored config", group: "misc" |
||||
} |
} |
||||
]; |
]; |
Write
Preview
Loading…
Cancel
Save
Reference in new issue