UnityBuildKit icon indicating copy to clipboard operation
UnityBuildKit copied to clipboard

Error while creating Unity project

Open jackcook opened this issue 7 years ago • 2 comments

First, I'd like to say this is a great idea for a project-- I've been struggling a lot with this myself. I tried running your tool today and it wouldn't create the Unity project. I could be doing something wrong, but I tried my best to follow your instructions from the README. Here is the log from the command:

Jacks-Mac-Pro:Storytime jackcook$ UnityBuildKit generate

----------
⚙️  Creating iOS Project
----------
No "base" settings found
No "debug config" settings found
No "base" settings found
No "release config" settings found
No "iOS" settings found
No "base" settings found
No "debug config" settings found
No "iOS" settings found
No "iOS" settings found
No "base" settings found
No "release config" settings found
No "iOS" settings found

----------
⚙️  Creating Unity Project
----------
Generating Unity project
This may take some time to complete


Generating Unity Editor scripts

----------
⚙️  Initializing projects
----------
Initializing Unity scene ExampleScene for iOS...
This will take some time to complete


----------
💥 An error was encountered while creating your projects
Failed to execute shell command: Initializing Unity Project

And here is my config file:

{
    "ios": {
        "projectName": "ExampleProject",
        "bundleId": "com.example.ExampleProject",
        "projectPath": "iOS/"
    },
    "unity": {
        "projectName": "ExampleProject",
        "applicationPath": "/Applications/Unity/Unity.app/Contents/MacOS/Unity",
        "version": "2017.2.1f1",
        "projectPath": "Unity/",
        "sceneNames": [
            "ExampleScene"
        ]
    }
}

Thanks in advance!

jackcook avatar Feb 03 '18 01:02 jackcook

@jackcook for a quick test, try setting the project paths to something like: /Users/me/Documents/Projects/MyProject/iOS/ / /Users/me/Documents/Projects/MyProject/Unity/ (inserting your own path as needed).

The scripts are run from the absolute paths and this is poorly documented on my part. I'm working on some updates to make this easier but this might work for you in the mean time.

enmiller avatar Feb 06 '18 20:02 enmiller

If you update to 1.1.3, the project paths are now relative and your original config file should work.

I've added a Wiki page to provide more information about the config file. Hopefully it helps some.

enmiller avatar Feb 06 '18 21:02 enmiller