gpt4 book ai didi

android - 如何仅列出 Android ADB 中的文件?

转载 作者:太空狗 更新时间:2023-10-29 12:43:29 25 4
gpt4 key购买 nike

我可以通过这个命令成功获取到目录名

ls -d */

但我不能只显示我设备中的文件。

最佳答案

您可以使用命令 ls -l | grep ^-

这是 ls 命令的完整选项列表。

Option  Description
-a Displays all files.
-b Displays nonprinting characters in octal.
-c Displays files by file timestamp.
-C Displays files in a columnar format (default)
-d Displays only directories.
-f Interprets each name as a directory, not a file.
-F Flags filenames.
-g Displays the long format listing, but exclude the owner name.
-i Displays the inode for each file.
-l Displays the long format listing.
-L Displays the file or directory referenced by a symbolic link.
-m Displays the names as a comma-separated list.
-n Displays the long format listing, with GID and UID numbers.
-o Displays the long format listing, but excludes group name.
-p Displays directories with /
-q Displays all nonprinting characters as ?
-r Displays files in reverse order.
-R Displays subdirectories as well.
-t Displays newest files first. (based on timestamp)
-u Displays files by the file access time.
-x Displays files as rows across the screen.
-1 Displays each entry on a line.

关于android - 如何仅列出 Android ADB 中的文件?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21725638/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com