unitysetup.powershell icon indicating copy to clipboard operation
unitysetup.powershell copied to clipboard

Start-UnityEditor should install missing Versions

Open jwittner opened this issue 7 years ago • 0 comments

If the version is not installed, the function should perform the -MissingVersionAction, which can be any of Confirm, ConfirmVersion, Install, Fallback, Error

MissingVersionAction, defaults to Confirm.

Example 'Confirm' output:

Would you like to?

[A] Install the missing version or [B] launch with latest version or [C] Specify a version or [D] Cancel.
C
What version?
>

Using ConfirmVersion skips the initial prompt, and asks just what version you'd like to use. Install auto installs without asking. Latest launches with the latest installed version. Error results in the exception we see now.

Note that defaulting to Confirm means a major version bump to account for the change in behavior. We could default to Error and make this a minor version bump. We could export a variable to control the default - $UnitySetupMissingVersionActionPreference so that people can change their default.

jwittner avatar Feb 15 '18 00:02 jwittner