diff --git a/dist/index.js b/dist/index.js index 7ae33ee0..826d5e43 100644 Binary files a/dist/index.js and b/dist/index.js differ diff --git a/dist/index.js.map b/dist/index.js.map index a5fdf9eb..a99941d2 100644 Binary files a/dist/index.js.map and b/dist/index.js.map differ diff --git a/src/model/platform-setup/setup-mac.ts b/src/model/platform-setup/setup-mac.ts index 2cac03f6..9a9f215a 100644 --- a/src/model/platform-setup/setup-mac.ts +++ b/src/model/platform-setup/setup-mac.ts @@ -9,9 +9,11 @@ class SetupMac { public static async setup(buildParameters: BuildParameters, actionFolder: string) { const unityEditorPath = `/Applications/Unity/Hub/Editor/${buildParameters.editorVersion}/Unity.app/Contents/MacOS/Unity`; - // Only install unity if the editor doesn't already exist - if (!fs.existsSync(unityEditorPath)) { + if (!fs.existsSync(this.unityHubPath)) { await SetupMac.installUnityHub(); + } + + if (!fs.existsSync(unityEditorPath)) { await SetupMac.installUnity(buildParameters); } @@ -40,12 +42,20 @@ class SetupMac { case 'iOS': command += `--module ios `; break; + case 'tvOS': + command += '--module tvos '; + break; case 'StandaloneOSX': command += `--module mac-il2cpp `; break; - case 'android': + case 'Android': command += `--module android `; break; + case 'WebGL': + command += '--module webgl '; + break; + default: + throw new Error(`Unsupported module for target platform: ${buildParameters.targetPlatform}.`); } command += `--childModules`;