Skip to content

Commit a617523

Browse files
committed
Add support for the link info namespace to ReadTarFS
1 parent 1dc42c6 commit a617523

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

fs/tarfs.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,6 +348,10 @@ def getinfo(self, path, namespaces=None):
348348
"is_dir": member.isdir(),
349349
}
350350

351+
if "link" in namespaces:
352+
raw_info["link"] = {
353+
"target": self._decode(member.linkname) if member.issym() else None
354+
}
351355
if "details" in namespaces:
352356
raw_info["details"] = {
353357
"size": member.size,

0 commit comments

Comments
 (0)