Execute symbolicatecrash from shell script

走远了吗. 提交于 2019-12-06 11:48:35

I think that you need first of all is execute this command

find /Applications/Xcode.app -name symbolicatecrash -type f

on your Terminal, this will retrieve the localization of your symbolicatecrash something like this

/Applications/Xcode.app/Contents/SharedFrameworks/DVTFoundation.framework/Versions/A/Resources/symbolicatecrash

then you need to update your script to this code

#!/usr/bin/bash
export DEVELOPER_DIR="/Applications/Xcode.app/Contents/Developer"

alias symbolicatecrash='/Applications/Xcode.app/Contents/SharedFrameworks/DVTFoundation.framework/Versions/A/Resources/symbolicatecrash'

i=0

for x in *.crash;
do
        symbolicatecrash $x MyApp.dSYM > $i.crash
        i=$((i+1))
done

and replace the direction of symbolicatecrash for the result given by the execution of find /Applications/Xcode.app -name symbolicatecrash -type f

and that is it,execute with sudo sh, I tested and result in this error

No crash report version in 0.crash at /Applications/Xcode.app/Contents/SharedFrameworks/DVTFoundation.framework/Versions/A/Resources/symbolicatecrash line 1007.

But I asume that this error is because I don't have any crash or dSYM so I think that now is working, I hope this help you

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!