mirror of
https://github.com/elseif/MikroTikPatch
synced 2026-07-17 10:39:40 +00:00
Update npk.py
Signed-off-by: elseif <elseif@live.cn>
This commit is contained in:
parent
04a831b463
commit
8c3278f477
2
npk.py
2
npk.py
@ -209,6 +209,8 @@ class NovaPackage(Package):
|
||||
self._parts.append(NpkPartItem(NpkPartID(part_id),part_data))
|
||||
def set_null_block(self):
|
||||
def rebuild_squashfs(data):
|
||||
if len(part.data) < 4 or part.data[:4] != b'hsqs':
|
||||
return part.data
|
||||
with open('squashfs.sfs', 'wb') as f:
|
||||
f.write(data)
|
||||
os.system('unsquashfs -d squashfs-root squashfs.sfs')
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user