Cannot build from command line

I am working on a presentation i am going to give related to “Build automation with Unity”.
For this presentation i would like to demonstrate building a Unity game from the command line.

The problem is that i cannot seem to get it working. I am using 2019.2 beta 7 (haven’t tried older versions yet).

This is the command line and arguments i am using:

The output log doesn’t mention anything interesting that i could find.
Does anyone know if this is a known bug? or am i doing something wrong here ?

Log file is also attached. Any help would be appreciated :slight_smile:

EDIT adding a build script (editor script that calls BuildPipeline.BuildPlayer) and calling that from the command line works, but the default built-in options like -buildOSX64Player are not working).

4741208–449867–Unity.txt (721 KB)

The command line to build Mac player is “-buildOSXUniversalPlayer”. Looks like documentation is incorrect. Can you submit a bug report?

I used the available commands from the docs I believe I also tried the option you wrote. I will try again and see if it works.

HA! that actually worked. i wonder why the other options didn’t work. they are listed in the documentation page here: Unity - Manual: Command-line arguments

Cannot build from command line using -buildOSX64player (Bug Case 1169361)

2 Likes

Thanks, we’ll fix the documentation.

The other ones didn’t work because the code doesn’t check for them :).

2 Likes