Show More
@@ -55,6 +55,10 b' try:' | |||
|
55 | 55 | pycompat.sysstr(package), encoding.strfromlocal(name) |
|
56 | 56 | ) |
|
57 | 57 | |
|
58 | def contents(package): | |
|
59 | for r in resources.contents(pycompat.sysstr(package)): | |
|
60 | yield encoding.strtolocal(r) | |
|
61 | ||
|
58 | 62 | |
|
59 | 63 | except (ImportError, AttributeError): |
|
60 | 64 | |
@@ -72,3 +76,9 b' except (ImportError, AttributeError):' | |||
|
72 | 76 | return os.path.isfile(pycompat.fsdecode(path)) |
|
73 | 77 | except (IOError, OSError): |
|
74 | 78 | return False |
|
79 | ||
|
80 | def contents(package): | |
|
81 | path = pycompat.fsdecode(_package_path(package)) | |
|
82 | ||
|
83 | for p in os.listdir(path): | |
|
84 | yield pycompat.fsencode(p) |
General Comments 0
You need to be logged in to leave comments.
Login now