如何选定的文件从Android的亚行拉复制文件、Android、亚行拉

2023-09-12 23:43:00 作者:时光冷透少年郎

我尝试使用ADB pull命令只有某些文件(JPG格式)复制到我的MacBook。我想亚行拉SD卡/ MYDIR / *。JPG,但它显然不跨$ P $磅常规EX pressions。我如何才能只JPG文件复制过来?我已经根深蒂固的手机有没有什么帮助。

I'm attempting to use the adb pull command to copy only certain files (jpg) to my macbook. I tried "adb pull sdcard/mydir/*.jpg" but it apparently doesn't interpret regular expressions. How can I get only the jpg files copied over? I have rooted the phone if that helps.

推荐答案

您可以将您的文件到其他文件夹,然后将整个文件夹。

You can move your files to other folder and then pull whole folder.


adb shell mkdir /sdcard/tmp
adb shell mv /sdcard/mydir/*.jpg /sdcard/tmp # move your jpegs to temporary dir
adb pull /sdcard/tmp/ # pull this directory (be sure to put '/' in the end)
adb shell mv /sdcard/tmp/* /sdcard/mydir/ # move them back
adb shell rmdir /sdcard/tmp # remove temporary directory