Return a list of items to be packed inside a fs image
(path)
| 86 | self.size = self.stat.st_size |
| 87 | |
| 88 | def listdir_items(path): |
| 89 | "Return a list of items to be packed inside a fs image" |
| 90 | |
| 91 | for name in os.listdir(path): |
| 92 | if name in exclude_names: |
| 93 | continue |
| 94 | |
| 95 | item = ItemToPack(path, name) |
| 96 | |
| 97 | if not (item.is_dir or item.is_file): |
| 98 | continue |
| 99 | |
| 100 | yield item |
| 101 | |
| 102 | def chunks(item, chunk_size): |
| 103 | "Iterate contents of a file in chunks of a given size" |
no test coverage detected