1. You want that $100.00 in your pocket or an Amazon Fire TV don't you? Well here's the deal. With our new updated look we are in desperate need of an updated logo. The 'old' one has certainly served us well, but it's time. Find all the details here: bit.ly/1q0k6Wa
  2. DroidForums.net is currently undergoing a major software upgrade. If you are experiencing any problems logging in please: Contact Us

How to detect first instance in Android logs?

Discussion in 'Android App Developers' started by Natey2, Mar 22, 2012.

  1. Natey2
    Offline

    Natey2 Active Member

    Joined:
    Oct 23, 2010
    Messages:
    1,339
    Likes Received:
    4
    Trophy Points:
    38
    I would like to detect the first occurrence of the substring "Low Memory" in my Android (logcat) logs.
    How would I do that on my Android device?

    In a normal Linux system, I could do something like:
    $ tail -f logfilename | grep 'Low Memory' > occurrences.txt

    Sent from my unrooted DroidX using Tapatalk