Answers:
忽略“ / F”开关,因为这是导致包含文件的原因。
来自tree /?
:
Graphically displays the folder structure of a drive or path.
TREE [drive:][path] [/F] [/A]
/F Display the names of the files in each folder.
/A Use ASCII instead of extended characters.
要输出到txt文件,请使用以下命令:(您将在驱动器C中找到,如下所示)
tree /a > "C:\_TREE-Output.txt"
>
,而其他答案则没有。