resolve tree formattting to a simplier and better visualization (#1305)

* resolve tree formattting to a simpier and easier visualization

Signed-off-by: aochuba <aochuba52@gmail.com>

* adding missing print statement

Signed-off-by: aochuba <aochuba52@gmail.com>

---------

Signed-off-by: aochuba <aochuba52@gmail.com>
Co-authored-by: Paige Patton <64206430+paigerube14@users.noreply.github.com>
This commit is contained in:
Aochuba S Aier
2026-05-13 10:27:41 -04:00
committed by GitHub
co-authored by Paige Patton
parent 64bdd3c6fb
commit 5dc79789a3
+3 -1
View File
@@ -85,7 +85,9 @@ def list_rollback(run_uuid: Optional[str]=None, scenario_type: Optional[str]=Non
files.sort()
for j, file in enumerate(files):
is_last_file = (j == len(files) - 1)
file_prefix = " └── " if is_last_dir else "└── " if is_last_file else ("│ ├── " if not is_last_dir else " ├── ")
dir_pad = " " if is_last_dir else ""
file_pad = "└── " if is_last_file else "├── "
file_prefix = dir_pad + file_pad
print(f"{file_prefix}{file}")
except PermissionError: