Add androidTargetSdkVersion as an option to update the Android SDK (#298)
* Add androidTargetSdkVersion as an option to update the Android SDK API level * Fix build script * Update default value * Add JAVA_HOME * Use Unity_path * Update src/model/android-versioning.test.ts Co-authored-by: Webber Takken <webber@takken.io> * Correct JAVA_HOME * Use unity_path * Update JAVA_HOME to use path found from 2020.3 * Dynamically determine JAVA_HOME * Update path determination Co-authored-by: Webber Takken <webber@takken.io>
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using System.Collections.Generic;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using UnityEditor;
|
||||
|
||||
namespace UnityBuilderAction.Input
|
||||
@@ -16,6 +17,8 @@ namespace UnityBuilderAction.Input
|
||||
PlayerSettings.Android.keyaliasName = keyaliasName;
|
||||
if (options.TryGetValue("androidKeyaliasPass", out string keyaliasPass) && !string.IsNullOrEmpty(keyaliasPass))
|
||||
PlayerSettings.Android.keyaliasPass = keyaliasPass;
|
||||
if (options.TryGetValue("androidTargetSdkVersion", out string androidTargetSdkVersion) && !string.IsNullOrEmpty(androidTargetSdkVersion))
|
||||
PlayerSettings.Android.targetSdkVersion = (AndroidSdkVersions) Enum.Parse(typeof(AndroidSdkVersions), androidTargetSdkVersion);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user