mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-23 16:23:12 +09:00
Fix --no-download-headless conflict in installer
Fix installer incorrectly exiting with a conflicting options errors when the --no-download-headless option was used in conjunction with the --factorio-dir option.
This commit is contained in:
1 parent
2872faab98
commit
e0161114e7
2 files changed
+6
-2
No files matched your search
@@ -11,6 +11,7 @@
|
|||||||
- Fixed generated systemd file for clusteriohost not enabling source maps.
|
- Fixed generated systemd file for clusteriohost not enabling source maps.
|
||||||
- Fixed ctl not exporting types used for adding commands to ctl plugins.
|
- Fixed ctl not exporting types used for adding commands to ctl plugins.
|
||||||
- Fixed controller only plugins throwing an error about missing a config field on startup out when added to hosts.
|
- Fixed controller only plugins throwing an error about missing a config field on startup out when added to hosts.
|
||||||
|
- Fixed installer incorrectly claiming the options --factorio-dir and --no-download-headless conflicts with each other.
|
||||||
|
|
||||||
|
|
||||||
## Version 2.0.0-alpha.14
|
## Version 2.0.0-alpha.14
|
||||||
|
|||||||
@@ -612,7 +612,7 @@ async function inquirerMissingArgs(args) {
|
|||||||
},
|
},
|
||||||
], answers);
|
], answers);
|
||||||
|
|
||||||
if (answers.downloadHeadless) {
|
if (!answers.factorioDir && answers.downloadHeadless) {
|
||||||
answers.factorioDir = "factorio";
|
answers.factorioDir = "factorio";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -760,7 +760,7 @@ async function main() {
|
|||||||
"Can be set to false using --no-download-headless.",
|
"Can be set to false using --no-download-headless.",
|
||||||
type: "boolean",
|
type: "boolean",
|
||||||
})
|
})
|
||||||
.conflicts("factorio-dir", "download-headless");
|
;
|
||||||
}
|
}
|
||||||
|
|
||||||
args = args.argv;
|
args = args.argv;
|
||||||
@@ -780,6 +780,9 @@ async function main() {
|
|||||||
|
|
||||||
let answers = await inquirerMissingArgs(args);
|
let answers = await inquirerMissingArgs(args);
|
||||||
if (answers.downloadHeadless) {
|
if (answers.downloadHeadless) {
|
||||||
|
if (answers.factorioDir !== "factorio") {
|
||||||
|
throw new InstallError("--download-headless option requires --factorio-dir to be set to factorio");
|
||||||
|
}
|
||||||
await downloadLinuxServer();
|
await downloadLinuxServer();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user