Skip to content

Commit

Permalink
including links in tree and fix missing type for links in file_list tome
Browse files Browse the repository at this point in the history
  • Loading branch information
adm1nPanda committed Jan 16, 2024
1 parent a1f2624 commit 86a8a17
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tavern/tomes/file_list/main.eldritch
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ def file_list(path):
type_str = ""
if f['type'] == "Directory":
type_str = "Dir"
if f['type'] == "Link":
type_str = "Link"
if f['type'] == "File":
type_str = "File"
print(f['permissions']+"\t"+f['owner']+"\t"+f['group']+"\t"+str(f['size'])+"\t"+f['modified']+"\t"+type_str+"\t"+f['file_name']+"\n")
Expand Down
2 changes: 2 additions & 0 deletions tavern/tomes/file_tree/main.eldritch
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ def file_list(path,tree):
if f['type'] == "Directory":
print(tree+"|---"+path+"/"+f['file_name']+"\n")
file_list(path+"/"+f['file_name'],tree)
if f['type'] == "Link":
print(tree+"|---"+f['file_name']+"\n")
if f['type'] == "File":
print(tree+"|---"+f['file_name']+"\n")
else:
Expand Down

0 comments on commit 86a8a17

Please sign in to comment.