Read the last N lines from logcat?
<p>I'd like to read the last n lines from logcat. Should this be working?:</p>

<pre><code>Process process = Runtime.getRuntime().exec("logcat -t -500");
BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(process.getInputStream()));
...
</code></pre>

<blockquote>
  <p>-t number</p>
</blockquote>

<p>Makes logcat print only entries from the position indicated by number and onward. A positive number indicates that the position is relative to the beginning of the log file, and a negative number indicates that the position is relative to the end of the log file.</p>

<p>Thanks</p>
