From c5357cc0bf59e60dd59f2b2a032245afd73e4acd Mon Sep 17 00:00:00 2001 From: Andreas Stöckel Date: Fri, 10 Apr 2015 11:29:57 +0200 Subject: Set default format to "xml" --- src/cli/Main.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'src/cli') diff --git a/src/cli/Main.cpp b/src/cli/Main.cpp index 1bd3725..a8d5bd8 100644 --- a/src/cli/Main.cpp +++ b/src/cli/Main.cpp @@ -124,8 +124,8 @@ int main(int argc, char **argv) "found.")( "output,o", po::value(&outputPath), "The output file name. Per default the input file name will be used.")( - "format,F", po::value(&format)->required(), - "The output format that shall be produced.")( + "format,F", po::value(&format), + "The output format that shall be produced (default is \"xml\").")( "flat,f", po::bool_switch(&flat)->default_value(false), "Works only for XML output. This serializes all referenced ontologies " "and typesystems into the output file." @@ -196,7 +196,11 @@ int main(int argc, char **argv) logger.note(std::string("Using ") + outputPath + std::string(" as output path.")); } - // check format. + + // check format, default to "xml" + if (format.empty()) { + format = "xml"; + } if (!formats.count(format)) { logger.error("Format must be one of: "); for (auto &f : formats) { -- cgit v1.2.3