mirror of
https://github.com/robmcmullen/atrcopy.git
synced 2024-06-14 18:29:35 +00:00
19 lines
449 B
Python
19 lines
449 B
Python
#!/usr/bin/env python
|
|
|
|
from atrutil import *
|
|
|
|
if __name__ == "__main__":
|
|
import sys
|
|
|
|
for args in sys.argv:
|
|
print args
|
|
with open(args, "rb") as fh:
|
|
atr = AtrDiskImage(fh)
|
|
print atr
|
|
for dirent in atr.files:
|
|
bytes = atr.get_file(dirent)
|
|
filename = dirent.get_filename()
|
|
with open(filename, "wb") as fh:
|
|
fh.write(bytes)
|
|
|