How to get Android crash logs?

前端 未结 17 1379
余生分开走
余生分开走 2020-11-28 18:07

I have an app that is not in the market place (signed with a debug certificate), but would like to get crash log data, whenever my application crashes. Where can I find a lo

17条回答
  •  自闭症患者
    2020-11-28 18:30

    1) Plug in Phone through USB (w/ Developer Debugging options enabled)

    2) Open Terminal and Navigate to your Android SDK (for Mac):

    cd ~/Library/Android/sdk/platform-tools

    3) Logcat from that directory (in your terminal) to generate a constant flow of logs (for Mac):

    ./adb logcat

    4) Open your app that crashes to generate crash logs

    5) Ctrl+C to stop terminal and look for the logs associated with the app that crashes. It may say something like the following:

    AndroidRuntime: FATAL EXCEPTION: main

提交回复
热议问题