One of the external libraries that my app uses have spaces in its logcat tag:
Log.d("Some External Library", "Debug Message");
How do I write the filter-spec in the logcat command to handle spaces? Logcat inside eclipse was able to filter it but I prefer the command line.
I've tried the following and they don't work:
adb logcat -s "Some External Library"
adb logcat -s Some\ External\ Library
adb logcat -s Some External Library
So my advice would be to use an pipe. Write:
adb logcat | grep 'Some External Library'
Maybe someone else has another idea.
If you need only debug messages write adb logcat '*:D' | grep 'Some External Library'
for more possible tags write adb logcat --help
The problem with this is, you can't use this solution in an adb shell
environment, because the file-system there is read-only. But this solution should give you more or less the results you want.
Commands like adb logcat -s 'Some External Library' or logcat -s '"Some External Library":D'
are not working.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With