tis-7zip

22.00-38
7-Zip is a free and open-source file archiver with a high compression ratio
95100 downloads
Download
View on luti logo
tis-7zip icon

  Description 

  • package : tis-7zip
  • version : 22.00-38
  • architecture : x86
  • categories : Utilities
  • maintainer : WAPT Team,Tranquil IT,Jimmy PELÉ
  • description : 7-Zip is a free and open-source file archiver with a high compression ratio
  • locale : all
  • target_os : windows
  • min_wapt_version : 2.0
  • sources : https://www.7-zip.org/download.html
  • installed_size :
  • impacted_process : 7zFM,7z,7zG
  • description_fr : 7-Zip est un logiciel gratuit et open source d'archivage de fichiers avec un taux de compression élevé
  • description_pl :
  • description_de : 7-Zip ist ein Datenkompressionsprogramm mit einer hohen Kompressionsrate
  • description_es : 7-Zip es un archivador de ficheros con una alta relación de compresión
  • description_pt : O 7-Zip é um compactador de arquivos com alta taxa de compressão
  • description_it :
  • description_nl :
  • description_ru : 7-Zip свободный файловый архиватор с высокой степенью сжатия данных
  • editor : Igor Pavlov
  • licence : LGPL
  • signature_date : 2022-06-25T17:00:10.912968
  • Homepage : https://www.7-zip.org/

  Setup.py 

# -*- coding: utf-8 -*-
from setuphelpers import *

r"""
Usable WAPT package functions: install(), uninstall(), session_setup(), audit(), update_package()

"""
# Declaring global variables - Warnings: 1) WAPT context is only available in package functions; 2) Global variables are not persistent between calls
bin_contains = "7z"
ext_file_association = [
    ".7z",
    ".zip",
    ".rar",
    ".001",
    ".cab",
    # ".iso",
    ".xz",
    ".txz",
    ".lzma",
    ".tar",
    ".cpio",
    ".bz2",
    ".bzip2",
    ".tbz2",
    ".tbz",
    ".gz",
    ".gzip",
    ".tgz",
    ".tpz",
    ".z",
    ".taz",
    ".lzh",
    ".lha",
    ".rpm",
    ".deb",
    ".arj",
    # ".vhd",
    # ".vhdx",
    ".wim",
    ".swm",
    ".esd",
    ".fat",
    ".ntfs",
    ".dmg",
    ".hfs",
    ".xar",
    ".squashfs",
]


def install():
    # Initializing variables
    package_version = control.version.split("-", 1)[0]
    bin_name = glob.glob("*%s*.msi" % bin_contains)[0]
    to_force = False

    # Uninstalling other versions of the software
    if len(installed_softwares(name="7-Zip")) >= 2:
        to_force = True
    for to_uninstall in installed_softwares(name="7-Zip"):
        if Version(to_uninstall["version"], 2) < Version(package_version, 2) or to_uninstall["key"] == "7-Zip" or force or to_force:
            print("Removing: %s (%s)" % (to_uninstall["name"], to_uninstall["version"]))
            killalltasks(control.impacted_process.split(","))
            try:
                run(uninstall_cmd(to_uninstall["key"]))
            except:
                wait_uninstallkey_absent(to_uninstall["key"])
                unregister_uninstall(to_uninstall["key"], win64app=to_uninstall["win64"])

    # Installing the software
    print("Installing: %s" % bin_name)
    if to_force:
        install_msi_if_needed(bin_name, min_version=package_version, force=to_force)
    else:
        install_msi_if_needed(bin_name, min_version=package_version)

    # File association for 7-Zip
    for ext in ext_file_association:
        register_ext(
            "7-zip",
            ext,
            '"%s" "%%1"' % (makepath(programfiles, "7-zip", "7zFM.exe")),
            icon="%s,1" % (makepath(programfiles, "7-zip", "7z.dll")),
        )

										

  Changelog 



Changelog software url : https://www.7-zip.org/history.txt



21.07-38
Now fixing mismatching software architectures
Reordered ext_file_association (to match with the software displaying) and no longer assiociate vhd* ext
min_wapt_version  : 2.0

21.07-36
Switching update_package() to update_package.py

									
  manifest.sha256