summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2019-12-27 23:40:18 +0100
committerCarl Hetherington <cth@carlh.net>2019-12-27 22:40:53 +0000
commit8c9194e9cf773af29aee3e5ad327478de62dac7e (patch)
tree61c2f8b8b8936cdcceed3531de1ef91d9ab27b67
parent1b2708e35873a8f952710348bc94d94e56feb447 (diff)
Add --config option to dcpomatic2 (#1703).
-rw-r--r--src/tools/dcpomatic.cc6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/tools/dcpomatic.cc b/src/tools/dcpomatic.cc
index 01a600282..4edfe4cd1 100644
--- a/src/tools/dcpomatic.cc
+++ b/src/tools/dcpomatic.cc
@@ -1445,6 +1445,7 @@ static const wxCmdLineEntryDesc command_line_description[] = {
{ wxCMD_LINE_OPTION, "c", "content", "add content file / directory", wxCMD_LINE_VAL_STRING, wxCMD_LINE_PARAM_OPTIONAL },
{ wxCMD_LINE_OPTION, "d", "dcp", "add content DCP", wxCMD_LINE_VAL_STRING, wxCMD_LINE_PARAM_OPTIONAL },
{ wxCMD_LINE_SWITCH, "v", "version", "show DCP-o-matic version", wxCMD_LINE_VAL_NONE, wxCMD_LINE_PARAM_OPTIONAL },
+ { wxCMD_LINE_OPTION, "", "config", "directory containing config.xml and cinemas.xml", wxCMD_LINE_VAL_STRING, wxCMD_LINE_PARAM_OPTIONAL },
{ wxCMD_LINE_PARAM, 0, 0, "film to load or create", wxCMD_LINE_VAL_STRING, wxCMD_LINE_PARAM_OPTIONAL },
{ wxCMD_LINE_NONE, "", "", "", wxCmdLineParamType (0), 0 }
};
@@ -1601,6 +1602,11 @@ private:
_dcp_to_add = wx_to_std (dcp);
}
+ wxString config;
+ if (parser.Found (wxT("config"), &config)) {
+ State::override_path = wx_to_std (config);
+ }
+
return true;
}