简体   繁体   English

iOS Firebase崩溃报告上传符号文件

[英]iOS Firebase Crash Reporting Uploading Symbol files

I integrated the firebase crash reporting into my app via cocoa pods . 我通过可可豆荚将firebase崩溃报告集成到我的应用程序中。 I created the run script ext. 我创建了运行脚本ext。

So it is working now. 所以它现在正在运作。 But my problem is, every time I try to build and run the app even in the simulator it tries to upload Symbol files and it takes too much time to build and run the app. 但我的问题是,每次我尝试构建和运行应用程序,即使在模拟器中它尝试上传符号文件,它需要太多的时间来构建和运行应用程序。

I used hockey app before. 我之前使用过曲棍球应用程序。 And in hockey app i am using hockey app's mac application to upload the symbol file when i want to. 在曲棍球应用程序中我正在使用曲棍球应用程序的mac应用程序来上传我想要的符号文件。 For example when my development and developer tests finish then i am releasing add hoc build then i am sending symbol files to hockey app. 例如,当我的开发和开发人员测试完成然后我发布add hoc构建然后我发送符号文件到曲棍球应用程序。

So my question is: What is the best use case flow of the firebase crash reporting? 所以我的问题是:firebase崩溃报告的最佳用例流程是什么? Can i upload symbol files before i release add hoc or App Store release? 我可以在发布add hoc或App Store发布之前上传符号文件吗? (Not every time) (不是每次)

Or is it possible to disable the "run script" for symbol file upload in the simulator builds. 或者是否可以在模拟器构建中禁用符号文件上载的“运行脚本”。

So I just keep the "Run script only when installing" checked on my symbol upload run script. 所以我只在我的符号上传运行脚本上选中“仅在安装时运行脚本”。

This ensures that it will only get run when archiving the app, and not during development (eg when releasing our app into the wild). 这确保了它只会在归档应用程序时运行,而不是在开发期间运行(例如,当我们将应用程序发布到野外时)。

截图

It seems you are looking for something like this: 看来你正在寻找这样的东西:

if [ ${PLATFORM_NAME} != "iphonesimulator" ]; then
    echo "Uploading Firebase Crash Symbols..."

    # Replace this with the GOOGLE_APP_ID from your GoogleService-Info.plist file
    GOOGLE_APP_ID=1:my:app:id

    # Replace the /Path/To/ServiceAccount.json with the path to the key you just downloaded
    "${PODS_ROOT}"/FirebaseCrash/upload-sym "/Path/To/ServiceAccount.json"
fi

So, at the very least, it only runs and uploads symbols when you are building for anything that isn't the simulator. 所以,至少,它只在你为不是模拟器的东西构建时运行和上传符号。

This would upload symbols only for release build configuration: 这将仅为release版本配置上载符号:

echo configuration is $CONFIGURATION

if [ $CONFIGURATION == Release ]; then

    echo uploading symbols

    # Replace this with the GOOGLE_APP_ID from your GoogleService-Info.plist file
    GOOGLE_APP_ID=1:************

    # Replace the /Path/To/ServiceAccount.json with the path to the key you just downloaded
    "${PODS_ROOT}"/FirebaseCrash/upload-sym "${SRCROOT}/GoogleServiceAccount.json"

else

    echo skipping symbols upload

fi

You don't have to run the script every time if you don't want to. 如果您不想,则不必每次都运行该脚本。 Minimally, you should run once for each build that's going to the store. 最低限度,你应该为每个去商店的构建运行一次。 You can upload before the app is released to the store. 您可以在应用程序发布到商店之前上传。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM