【已解决】'grep' 不是内部或外部命令,也不是可运行的程序 或批处理文件。

win10,cmd环境下运行:adb shell top |grep com.*****s.j*

报错!!!


解决办法2种:

方法一:grep 更改为 findstr     adb shell top | findstr com.******.**

方法二:先cmd输入adb shell,然后在输入top | grep com.*****.**

原理:

方法一是因为在cmd环境下,所以要用findstr

方法二是因为在shell环境下

终于解决了!!!

原文地址:https://www.cnblogs.com/jason-syc/p/13279563.html