summaryrefslogtreecommitdiff
path: root/src/lib/create_cli.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2021-05-03 11:17:34 +0200
committerCarl Hetherington <cth@carlh.net>2021-05-03 20:18:04 +0200
commit689fa55d1529ad88449ca464e9107c4dcc54d1cb (patch)
treeedd1264941263f2fa25a98d61f98c87876c5b667 /src/lib/create_cli.cc
parent0aabe4060ea4bad7c7caac633aef0737fccff8c2 (diff)
C++11 tidying.
Diffstat (limited to 'src/lib/create_cli.cc')
-rw-r--r--src/lib/create_cli.cc12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/lib/create_cli.cc b/src/lib/create_cli.cc
index 819f17f6e..2258f8a2e 100644
--- a/src/lib/create_cli.cc
+++ b/src/lib/create_cli.cc
@@ -1,5 +1,5 @@
/*
- Copyright (C) 2019 Carl Hetherington <cth@carlh.net>
+ Copyright (C) 2019-2021 Carl Hetherington <cth@carlh.net>
This file is part of DCP-o-matic.
@@ -18,20 +18,22 @@
*/
+
+#include "compose.hpp"
+#include "config.h"
#include "create_cli.h"
#include "dcp_content_type.h"
#include "ratio.h"
-#include "config.h"
-#include "compose.hpp"
#include <dcp/raw_convert.h>
+#include <iostream>
#include <string>
-#include <iostream>
using std::string;
using std::cout;
using boost::optional;
+
string CreateCLI::_help =
"\nSyntax: %1 [OPTION] <CONTENT> [OPTION] [<CONTENT> ...]\n"
" -v, --version show DCP-o-matic version\n"
@@ -54,6 +56,7 @@ string CreateCLI::_help =
" --left-eye next piece of content is for the left eye\n"
" --right-eye next piece of content is for the right eye\n";
+
template <class T>
void
argument_option (int& n, int argc, char* argv[], string short_name, string long_name, bool* claimed, optional<string>* error, T* out)
@@ -72,6 +75,7 @@ argument_option (int& n, int argc, char* argv[], string short_name, string long_
*claimed = true;
}
+
CreateCLI::CreateCLI (int argc, char* argv[])
: version (false)
, encrypt (false)