|
@@ -9,9 +9,11 @@ import java.util.Set;
|
|
|
public class FileCase {
|
|
|
Set<String> fileList = new HashSet<>();
|
|
|
|
|
|
+ private String fileDir = "D:\\github\\MyHome\\";
|
|
|
+
|
|
|
@Test
|
|
|
public void testFile() {
|
|
|
- String filePath = "D:\\github\\MyHome\\文章";
|
|
|
+ String filePath = fileDir + "文章";
|
|
|
File[] files = new File(filePath).listFiles();
|
|
|
deepFile(files, 0);
|
|
|
}
|
|
@@ -27,7 +29,7 @@ public class FileCase {
|
|
|
} else {
|
|
|
if (!isEndWith(file.getName(), "png", "gif", "jpg")) {
|
|
|
System.out.println(
|
|
|
- appendIndex("-", index) + "\t" + "[" + file.getName() + "](" + mdPath(file.getPath(),
|
|
|
+ appendIndex("-", 1) + "\t" + "[" + file.getName() + "](" + mdPath(file.getPath(),
|
|
|
"D:\\github\\MyHome", ".") + ")");
|
|
|
}
|
|
|
}
|