tree命令
在windows的命令行中使用tree命令即可打印该指定目录的文件树状结构图。
PS E:\work> tree /?
以图形显示驱动器或路径的文件夹结构。
TREE [drive:][path] [/F] [/A]
/F 显示每个文件夹中文件的名称。
/A 使用 ASCII 字符,而不使用扩展字符。
将打印的目录树保存到指定文件中:
tree /F > 目录结构图.txt
打印目录树:
tree /F
实例:
打印新建Android项目的文件树结构:
PS C:\Users\Makesky\Desktop\MyApplication> tree /F
卷 Windows 的文件夹 PATH 列表
卷序列号为 CC04-B3FA
C:.
│ .gitignore
│ build.gradle
│ gradle.properties
│ gradlew
│ gradlew.bat
│ local.properties
│ MyApplication.iml
│ settings.gradle
│
├─.gradle
│ └─3.3
│ └─taskArtifacts
├─.idea
│ │ compiler.xml
│ │ gradle.xml
│ │ misc.xml
│ │ modules.xml
│ │ runConfigurations.xml
│ │ workspace.xml
│ │
│ ├─copyright
│ │ profiles_settings.xml
│ │
│ └─libraries
│ constraint_layout_1_0_2.xml
│ constraint_layout_solver_1_0_2.xml
│ espresso_core_2_2_2.xml
│ espresso_idling_resource_2_2_2.xml
│ exposed_instrumentation_api_publish_0_5.xml
│ hamcrest_core_1_3.xml
│ hamcrest_integration_1_3.xml
│ hamcrest_library_1_3.xml
│ javawriter_2_1_1.xml
│ javax_annotation_api_1_2.xml
│ javax_inject_1.xml
│ jsr305_2_0_1.xml
│ junit_4_12.xml
│ rules_0_5.xml
│ runner_0_5.xml
│
├─app
│ │ .gitignore
│ │ app.iml
│ │ build.gradle
│ │ proguard-rules.pro
│ │
│ ├─build
│ │ └─intermediates
│ │ └─incremental
│ │ ├─packageDebug
│ │ │ └─zip-cache
│ │ ├─packageDebugAndroidTest
│ │ │ └─zip-cache
│ │ └─packageRelease
│ │ └─zip-cache
│ ├─libs
│ └─src
│ ├─androidTest
│ │ └─java
│ │ └─com
│ │ └─makesky
│ │ └─myapplication
│ │ ExampleInstrumentedTest.java
│ │
│ ├─main
│ │ │ AndroidManifest.xml
│ │ │
│ │ ├─java
│ │ │ └─com
│ │ │ └─makesky
│ │ │ └─myapplication
│ │ │ MainActivity.java
│ │ │
│ │ └─res
│ │ ├─drawable
│ │ ├─layout
│ │ │ activity_main.xml
│ │ │
│ │ ├─mipmap-hdpi
│ │ │ ic_launcher.png
│ │ │ ic_launcher_round.png
│ │ │
│ │ ├─mipmap-mdpi
│ │ │ ic_launcher.png
│ │ │ ic_launcher_round.png
│ │ │
│ │ ├─mipmap-xhdpi
│ │ │ ic_launcher.png
│ │ │ ic_launcher_round.png
│ │ │
│ │ ├─mipmap-xxhdpi
│ │ │ ic_launcher.png
│ │ │ ic_launcher_round.png
│ │ │
│ │ ├─mipmap-xxxhdpi
│ │ │ ic_launcher.png
│ │ │ ic_launcher_round.png
│ │ │
│ │ └─values
│ │ colors.xml
│ │ strings.xml
│ │ styles.xml
│ │
│ └─test
│ └─java
│ └─com
│ └─makesky
│ └─myapplication
│ ExampleUnitTest.java
│
├─build
│ └─android-profile
│ profile-2018-09-14-08-31-32-071.rawproto
│
└─gradle
└─wrapper
gradle-wrapper.jar
gradle-wrapper.properties