(startpath)
| 14 | import os |
| 15 | |
| 16 | def list_files(startpath): |
| 17 | for root, dirs, files in sorted(os.walk(startpath)): |
| 18 | level = root.replace(startpath, '').count(os.sep) |
| 19 | indent = ' ' * 4 * (level) |
| 20 | print(' {}- {}:'.format(indent, os.path.basename(root).capitalize()),) |
| 21 | subindent = ' ' * 4 * (level + 1) |
| 22 | for f in sorted(files): |
| 23 | title = str(f).replace('.md', '') |
| 24 | filepath = os.path.join(root, f) |
| 25 | print(' {}- {}: {}'.format(subindent, title, filepath)) |
| 26 | |
| 27 | list_files("zkEVM") |