Ensure --export implies --editor
Fixes #30149
(cherry picked from commit 9ebc146383
)
This commit is contained in:
parent
c7293e9b30
commit
2bbf5a31ec
|
@ -582,6 +582,10 @@ Error Main::setup(const char *execpath, int argc, char *argv[], bool p_second_ph
|
||||||
|
|
||||||
auto_build_solutions = true;
|
auto_build_solutions = true;
|
||||||
editor = true;
|
editor = true;
|
||||||
|
} else if (I->get() == "--export" || I->get() == "--export-debug") { // Export project
|
||||||
|
|
||||||
|
editor = true;
|
||||||
|
main_args.push_back(I->get());
|
||||||
#endif
|
#endif
|
||||||
} else if (I->get() == "--no-window") { // disable window creation, Windows only
|
} else if (I->get() == "--no-window") { // disable window creation, Windows only
|
||||||
|
|
||||||
|
@ -1322,20 +1326,10 @@ bool Main::start() {
|
||||||
removal_docs.push_back(args[j]);
|
removal_docs.push_back(args[j]);
|
||||||
} else if (args[i] == "--export") {
|
} else if (args[i] == "--export") {
|
||||||
editor = true; //needs editor
|
editor = true; //needs editor
|
||||||
if (i + 1 < args.size()) {
|
_export_preset = args[i + 1];
|
||||||
_export_preset = args[i + 1];
|
|
||||||
} else {
|
|
||||||
ERR_PRINT("Export preset name not specified");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else if (args[i] == "--export-debug") {
|
} else if (args[i] == "--export-debug") {
|
||||||
editor = true; //needs editor
|
editor = true; //needs editor
|
||||||
if (i + 1 < args.size()) {
|
_export_preset = args[i + 1];
|
||||||
_export_preset = args[i + 1];
|
|
||||||
} else {
|
|
||||||
ERR_PRINT("Export preset name not specified");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
export_debug = true;
|
export_debug = true;
|
||||||
#endif
|
#endif
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue