Install mac modules based on target platform for greater flexibility (#481)

This commit is contained in:
AndrewKahr 2022-12-14 01:27:36 -08:00 committed by GitHub
parent 5bd589e19f
commit 9329b7369c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 16 additions and 4 deletions

BIN
dist/index.js generated vendored

Binary file not shown.

BIN
dist/index.js.map generated vendored

Binary file not shown.

View File

@ -32,11 +32,23 @@ class SetupMac {
private static async installUnity(buildParameters: BuildParameters, silent = false) { private static async installUnity(buildParameters: BuildParameters, silent = false) {
const unityChangeset = await getUnityChangeset(buildParameters.editorVersion); const unityChangeset = await getUnityChangeset(buildParameters.editorVersion);
const command = `${this.unityHubPath} -- --headless install \ let command = `${this.unityHubPath} -- --headless install \
--version ${buildParameters.editorVersion} \ --version ${buildParameters.editorVersion} \
--changeset ${unityChangeset.changeset} \ --changeset ${unityChangeset.changeset} `;
--module mac-il2cpp \
--childModules`; switch (buildParameters.targetPlatform) {
case 'iOS':
command += `--module ios `;
break;
case 'StandaloneOSX':
command += `--module mac-il2cpp `;
break;
case 'android':
command += `--module android `;
break;
}
command += `--childModules`;
// Ignoring return code because the log seems to overflow the internal buffer which triggers // Ignoring return code because the log seems to overflow the internal buffer which triggers
// a false error // a false error