Skip to content

Instantly share code, notes, and snippets.

@uyjulian
Created March 14, 2025 17:49
Show Gist options
  • Save uyjulian/1131369bc2d70b87f81d41e00312a3cd to your computer and use it in GitHub Desktop.
Save uyjulian/1131369bc2d70b87f81d41e00312a3cd to your computer and use it in GitHub Desktop.
# SPDX-License-Identifier: MIT
# Decompress linux_p7.daz from SCPN-60160
import zlib
import sys
import io
with open(sys.argv[1], "rb") as f:
iobj = zlib.decompressobj()
f.seek(0, 2)
sz = f.tell()
f.seek(0, 0)
with open(sys.argv[2], "wb") as wf:
for i in range(500):
wf.write(iobj.decompress(f.read(0x40000)))
if iobj.eof:
break
used = f.tell()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment