在命令行上过滤 Logcat 日志

2024-03-02

public static final TAG = "Legendry Eagle";

问题:我想查看日志"Legendry Eagle"从命令行。

I tried:

 adb logcat -s "Legendry Eagle" 
 adb logcat -s <Legendry Eagle>

但它仍然不起作用。


如果您只想显示特定标记的 logcat,请按以下步骤操作:

adb logcat YourTAGHere:Priority *:S

The *:S很重要,因为它将所有其他标签设置为静默。如果我只想追踪我的MainActivity详细级别的标签,语法如下所示。

adb logcat MainActivity:V *:S

Edit:我没有找到过滤掉带有空格的标签的好方法。LegendryEagle工作正常,但我无法过滤掉Legendry Eagle

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

在命令行上过滤 Logcat 日志 的相关文章

随机推荐