diff --git a/doc/changelog.txt b/doc/changelog.txt index bf36b96..c861b73 100644 --- a/doc/changelog.txt +++ b/doc/changelog.txt @@ -4,10 +4,10 @@ * Added support for shorten handling SHN (.shn) files. * Added support for flac handling FLAC (.flac) files. * Added support for the BSD cpio and tar programs. -* Generate standalone Windows installer. +* Added support for lhasa handling LZH (.lzh, .lha) files. +* Generate standalone Windows .exe and Linux .rpm installer. * Initialize the internal MIME database correct on all platforms. * Improved option compatibility for the ar, cpio and tar programs. -* Support RPM installer generation with cx_Freeze. 0.16 "Game of thrones" (released 12.5.2012) diff --git a/patoolib/__init__.py b/patoolib/__init__.py index 01e2507..7ad6bf9 100644 --- a/patoolib/__init__.py +++ b/patoolib/__init__.py @@ -128,6 +128,7 @@ ArchivePrograms = { }, 'lzh': { None: ('lha',), + 'extract': ('lhasa',), }, 'lzip': { 'extract': ('plzip', 'lzip', 'clzip', 'pdlzip'), diff --git a/patoolib/programs/lhasa.py b/patoolib/programs/lhasa.py new file mode 100644 index 0000000..b7a3e81 --- /dev/null +++ b/patoolib/programs/lhasa.py @@ -0,0 +1,18 @@ +# -*- coding: utf-8 -*- +# Copyright (C) 2012 Bastian Kleineidam +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . +"""Archive commands for the lhasa program.""" +from .lha import extract_lzh + diff --git a/tests/test_archives.py b/tests/test_archives.py index c505b57..4dd3c98 100644 --- a/tests/test_archives.py +++ b/tests/test_archives.py @@ -449,6 +449,11 @@ class TestArchives (ArchiveTest): self.program = 'lha' self.archive_commands('t.lha') + @needs_program('lhasa') + def test_lhasa (self): + self.program = 'lhasa' + self.archive_extract('t.lha') + @needs_program('arc') def test_arc (self): self.program = 'arc'