(paths, algorithm="md5")
| 77 | |
| 78 | |
| 79 | def hash_files(paths, algorithm="md5"): |
| 80 | h = hashlib.new(algorithm) |
| 81 | for path in paths: |
| 82 | with open(path, "rb") as fi: |
| 83 | while True: |
| 84 | chunk = fi.read(262144) |
| 85 | if not chunk: |
| 86 | break |
| 87 | h.update(chunk) |
| 88 | return h.hexdigest() |
| 89 | |
| 90 | |
| 91 | def make_VIProductVersion(version): |
no outgoing calls
no test coverage detected