Search Unity

Question Install apple silicon (arm64) using hub cli

Discussion in 'Unity Hub' started by unity_EA3DE52BED9CD2E0DD40, Apr 11, 2023.

  1. unity_EA3DE52BED9CD2E0DD40

    unity_EA3DE52BED9CD2E0DD40

    Joined:
    Oct 25, 2022
    Posts:
    5
    Hi! How do you install apple silicon editor using unity hub cli without manual inputs?


    When I try the following, it fails unable to find editor version.

    /Applications/Unity\ Hub.app/Contents/MacOS/Unity\ Hub -- --headless install --version "2021.3.22f1 (Apple silicon)"
    Error while installing an editor or a module. Error: Provided editor version does not match to any known Unity Editor versions.


    On the other hand if I remove the explicit architecture it gives me manual selection.

    /Applications/Unity\ Hub.app/Contents/MacOS/Unity\ Hub -- --headless install --version "2021.3.22f1"
    ? [B]Multiple editors found for given version "2021.3.22f1". Please select:[/B]
    ❯ 2021.3.22f1 (Intel)
    2021.3.22f1 (Apple silicon)



    I want to automate this in a build machine and would like to find a no manual input solution :)
     
    willykc likes this.
  2. robinfischerinnogames

    robinfischerinnogames

    Joined:
    Apr 7, 2017
    Posts:
    13
    We are also very interested in this. So annoying that Unity Hub can't install Apple Silicon directly via CLI!
     
    dzmitryzplaytika likes this.
  3. unity_EA3DE52BED9CD2E0DD40

    unity_EA3DE52BED9CD2E0DD40

    Joined:
    Oct 25, 2022
    Posts:
    5
    @robinfischerinnogames
    Hi!
    This has been silently introduced with latest hub cli e.g. --architecture arm64
    /Applications/Unity\ Hub.app/Contents/MacOS/Unity\ Hub -- --headless install --version "2021.3.27f1" --module android android-sdk-ndk-tools ios windows-mono --architecture arm64 --childModules
     
  4. robinfischerinnogames

    robinfischerinnogames

    Joined:
    Apr 7, 2017
    Posts:
    13
    Thank you for coming back with this information!
    I totally overlooked it in the help. (Or it is super new...)

    This works.
     
  5. unity_EA3DE52BED9CD2E0DD40

    unity_EA3DE52BED9CD2E0DD40

    Joined:
    Oct 25, 2022
    Posts:
    5
    I believe it was introduced with June 20th release of unity hub version 3.5.0

    But unfortunately neither official documentation nor changelog includes this addition. Hopefully the hub team can improve in communication. :)

    3.5.0
    Jun. 20, 2023
    • Removed the 40 project limit.
    • Improved cleanup of download files from default temp directory or user's custom downloads location.
    • Added a flag that defines the log level, to improve log readability and user support.
    • Improved screen reader support on Learn and Community.
    • Fixed noticeable delay when starring projects.
     
  6. robinfischerinnogames

    robinfischerinnogames

    Joined:
    Apr 7, 2017
    Posts:
    13
    I just tested it out and it seems to only work with editors listed via the command
    Code (CSharp):
    1. /Applications/Unity\ Hub.app/Contents/MacOS/Unity\ Hub -- --headless editors -r
    If I try it with a slightly older Editor version:

    Code (CSharp):
    1. /Applications/Unity\ Hub.app/Contents/MacOS/Unity\ Hub -- --headless install --version 2021.3.23f1 --changeset 213b516bf396 --module android android-sdk-ndk-tools ios webgl --architecture arm64 --childModules
    the install is a success but I still get the Intel Editor version when checking the Unity.app in the /Applications/Unity/2021.3.23f1 directory.

    So version 2021.3.27f1 worked. But 2021.3.23f1 didn't work...
    Can you confirm this? Or do you have a workaround?
     
  7. androshchuk-vladyslav

    androshchuk-vladyslav

    Joined:
    Dec 13, 2015
    Posts:
    127
    Hello.

    I already wrote in a different thread.

    I see that we got an option "--architecture|-a <architecture> editor architecture to install (x86_64 or arm64)", but it doesn't work with the "--changeset" flag, which makes it useless.

    As far as I know, the only workaround is to use the u3d ruby gem or write the code yourself.

    I clearly don't understand, why this isn't implemented.
     
  8. unity_EA3DE52BED9CD2E0DD40

    unity_EA3DE52BED9CD2E0DD40

    Joined:
    Oct 25, 2022
    Posts:
    5
    Ahh, i was too excited too soon and did not noticed it installed intel version... :(
     
  9. robinfischerinnogames

    robinfischerinnogames

    Joined:
    Apr 7, 2017
    Posts:
    13
    This has now been fixed with Unity Hub version 3.5.1 ! Enjoy