#!/usr/bin/env python3 """ Read only, Amiga LZX[1] archiver Virtual filesystem executive for Midnight Commander. Tested against python 3.8, unlzx[1] 1.1 and mc 4.8.22 [1] ftp://us.aminet.net/pub/aminet/misc/unix/unlzx.c.gz.readme Changelog: 1.3 Code cleanup 1.2 Use python3 1.1 Moved common code into extfslib library 1.0 Initial release Author: Roman 'gryf' Dobosz Date: 2023-10-20 Version: 1.3 Licence: BSD """ import os import re import shutil import subprocess import sys import tempfile import extfslib class ULzx(extfslib.Archive): """LZX archive handle. Provides interface to MC's extfs subsystem""" LINE_PAT = re.compile(r"^\s+(?P\d+)\s+" r"((n/a)|\d+)\s" r"(?P