Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Firebase dSYM uploads from UCB

Discussion in 'Unity Cloud Build' started by nmd2, Jun 25, 2020.

  1. nmd2

    nmd2

    Joined:
    Mar 19, 2019
    Posts:
    13
    I need to be able to upload the dSYMs from the cloud build to Firebase from iOS builds, as per this documentation:
    https://firebase.google.com/docs/crashlytics/get-deobfuscated-reports?platform=ios

    There's an upload utility in the Xcode project:
    Pods/FirebaseCrashlytics/upload-symbols

    I can add a post build script to do the upload, I just need to know 2 things:
    1) The path to the Xcode project
    2) The path to the dSYM

    Also will
    Pods/FirebaseCrashlytics/upload-symbols
    have execute permission?

    Thanks
     
  2. nmd2

    nmd2

    Joined:
    Mar 19, 2019
    Posts:
    13
    I've answered my own question, so will leave it here to save other people time in the future.

    Use Fastlane upload_symbols_to_crashlytics to upload the dsym to Firebase
    http://docs.fastlane.tools/actions/upload_symbols_to_crashlytics/#upload_symbols_to_crashlytics

    I set up a Fastlane.json and Fastfile as per this post:
    https://forum.unity.com/threads/xcode-9-multiple-provisioning-profiles.545121/

    Fastlane.json
    Code (JavaScript):
    1. {
    2.     "fastfile": "Fastfile",
    3.     "lanes": {
    4.         "pre_build": "",
    5.         "post_build": "upload_dsym"
    6.     }
    7. }
    Then create a "Fastfile" text document, with no extension, that determines a "lane" for the build to run and upload the dSYM. Ensure the gsp_path to GoogleService-Info.plist is correct from your Xcode project root (do a local build first to be sure)

    Fastfile
    Code (JavaScript):
    1. lane :upload_dsym do
    2.     upload_symbols_to_crashlytics(
    3.         {
    4.             gsp_path: "./GoogleService-Info.plist"
    5.           }
    6.     )
    7. end
    At the end of your full build log in UCB, you should see logs like these:

    16038: Uploading 'clientdev.app.dSYM'...
    16039: Uploading 'UnityFramework.framework.dSYM'...
    16040: Successfully uploaded dSYM files to Crashlytics
     
  3. hexware

    hexware

    Joined:
    Aug 30, 2013
    Posts:
    7

    Hi,
    I'm trying to make it the same way what u did, but I got this line in the console:
    User Lane 'upload_dsym' was not found!