Android: Better Logging Output

Ever got annoyed by the flood of information in Android's adb logcat output? Luckily Google Engineer Jeff Sharkey put together a Python script to make the output visually more appealing and easier to follow. Below are a few tipps on how to effectively combine with adb logcat's parameters and options.

Colored Logcat Output
  1. Download from Jeff Sharky's blog
  2. Copy the script to your local ~/bin folder and make it executable
  3. mkdir ~/bin cp ~/Downloads/coloredl chmod +x ~/bin/
  4. Add ~/bin permanently to your $PATH variable. Either in your .bashrc or .zshrc (or whatever shell you use) add or modify this line:
  5. export PATH=$HOME/bin:$PATH
You can either use it directly, by simply entering, or you can use adb logcat with all it's parameters and just pipe it into

Show only DEBUG output from the MyApp TAG. Everything else is SILENT: *:s (not shown)
adb -d logcat "*:S MyApp:D" |
Show only WARNING, ERROR and FATAL output. Great for checking on exceptions.
adb -d logcat "*:W" |
Logcat priorities
  • V — Verbose (lowest priority)
  • D — Debug
  • I — Info
  • W — Warning
  • E — Error
  • F — Fatal
  • S — Silent (highest priority, on which nothing is ever printed)
Special options
  • adb logcat -c clears the entire log

I've just launched a new side project of mine:

Bugfender - A modern remote logger tailor-made for mobile development

It's currently free and you can sign up here:

Any kind of feedback is more than appreciated :-)

1 comment:

  1. Thanks for posting. Is there windows compatible version of this script? I found it uses fcntl module (not available in Windows distribution).