1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2025-08-08 14:55:17 +00:00

Display --help message if run without arguments

Fixes #389
This commit is contained in:
Jermolene 2014-03-05 11:13:58 +00:00
parent f83443feac
commit c277370e48

View File

@ -223,8 +223,12 @@ exports.startup = function() {
}); });
} else { } else {
// On the server, start a commander with the command line arguments // On the server, start a commander with the command line arguments
var args = $tw.boot.argv;
if(args.length === 0) {
args = ["--help"];
}
commander = new $tw.Commander( commander = new $tw.Commander(
$tw.boot.argv, args,
function(err) { function(err) {
if(err) { if(err) {
console.log("Error: " + err); console.log("Error: " + err);