comparison OrthancServer/main.cpp @ 3526:f07352e0375c

new configuration option ExecuteLuaEnabled
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 26 Sep 2019 10:03:35 +0200
parents d2b9981017c4
children 2090ec6a83a5
comparison
equal deleted inserted replaced
3525:8c66c9c2257b 3526:f07352e0375c
514 << " --logdir=[dir]\tdirectory where to store the log files" << std::endl 514 << " --logdir=[dir]\tdirectory where to store the log files" << std::endl
515 << "\t\t\t(by default, the log is dumped to stderr)" << std::endl 515 << "\t\t\t(by default, the log is dumped to stderr)" << std::endl
516 << " --logfile=[file]\tfile where to store the log of Orthanc" << std::endl 516 << " --logfile=[file]\tfile where to store the log of Orthanc" << std::endl
517 << "\t\t\t(by default, the log is dumped to stderr)" << std::endl 517 << "\t\t\t(by default, the log is dumped to stderr)" << std::endl
518 << " --config=[file]\tcreate a sample configuration file and exit" << std::endl 518 << " --config=[file]\tcreate a sample configuration file and exit" << std::endl
519 << "\t\t\t(if file is \"-\", dumps to stdout)" << std::endl
519 << " --errors\t\tprint the supported error codes and exit" << std::endl 520 << " --errors\t\tprint the supported error codes and exit" << std::endl
520 << " --verbose\t\tbe verbose in logs" << std::endl 521 << " --verbose\t\tbe verbose in logs" << std::endl
521 << " --trace\t\thighest verbosity in logs (for debug)" << std::endl 522 << " --trace\t\thighest verbosity in logs (for debug)" << std::endl
522 << " --upgrade\t\tallow Orthanc to upgrade the version of the" << std::endl 523 << " --upgrade\t\tallow Orthanc to upgrade the version of the" << std::endl
523 << "\t\t\tdatabase (beware that the database will become" << std::endl 524 << "\t\t\tdatabase (beware that the database will become" << std::endl
1434 1435
1435 std::string target = argument.substr(9); 1436 std::string target = argument.substr(9);
1436 1437
1437 try 1438 try
1438 { 1439 {
1439 SystemToolbox::WriteFile(configurationSample, target); 1440 if (target == "-")
1441 {
1442 // New in 1.5.8: Print to stdout
1443 std::cout << configurationSample;
1444 }
1445 else
1446 {
1447 SystemToolbox::WriteFile(configurationSample, target);
1448 }
1440 return 0; 1449 return 0;
1441 } 1450 }
1442 catch (OrthancException&) 1451 catch (OrthancException&)
1443 { 1452 {
1444 LOG(ERROR) << "Cannot write sample configuration as file \"" << target << "\""; 1453 LOG(ERROR) << "Cannot write sample configuration as file \"" << target << "\"";