tis-7zip
Version : 16.04-5
- package : tis-7zip
- editor :
- version : 16.04-5
- licence :
- architecture : all
- locale :
- description : compression archivage 7-zip pour x86 et x64
- description_fr :
- min_os_version :
- max_os_version :
- min_wapt_version :
- installed_size :
- impacted_process :
- signature_date : 20170720-154945
- maintainer : TIS, Amelie LE JEUNE
setup.py
#!/usr/bin/python # -*- coding: utf-8 -*- # ----------------------------------------------------------------------- # This file is part of WAPT # Copyright (C) 2013 Tranquil IT Systems http://www.tranquil.it # WAPT aims to help Windows systems administrators to deploy # setup and update applications on users PC. # # WAPT 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. # # WAPT 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 WAPT. If not, see <http://www.gnu.org/licenses/>. # # ----------------------------------------------------------------------- from setuphelpers import * import glob uninstallkey=[] product_version = '16.04' setup_version = product_version.replace('.','') setup_filename_x86 = '7z%s.msi' % setup_version setup_filename_x64 = '7z%s-x64.msi' % setup_version def install(): broken_7zip = [ soft for soft in installed_softwares('7-zip') if Version(soft['version']) < Version(product_version) ] if broken_7zip: for uninstall in broken_7zip: cmd = WAPT.uninstall_cmd(uninstall['key']) print(u'uninstalling %s' % (uninstall['name'],)) # on execute la commande de desinstallation run(cmd) print("Installing 7-Zip %s"%(control.version,)) if iswin64(): install_msi_if_needed(setup_filename_x64,killbefore=['7zFM.exe']) else: install_msi_if_needed(setup_filename_x86,killbefore=['7zFM.exe']) # association des extensions a 7ZIP for ext in ('.001','.7z','.arj','.bz2','.bzip2','.cab','.cpio','.deb','.dmg','.fat', '.gz','.gzip','.hfs','.iso','.lha','.lzh','.lzma','.ntfs','.rar','.rpm', '.squashfs','.swm','.tar','.taz','.tbz','.tbz2','.tgz','.tpz','.txz','.vhd', '.wim','.xar','.xz','.z','.zip', '.zipe'): register_ext('7-zip',ext,'"%s" "%%1"' % (makepath(programfiles,'7-zip','7zFM.exe'),),icon="%s,1" % (makepath(programfiles,'7-zip','7z.dll'))) def update_package(control): if not isfile(setup_filename_x86): wget('http://www.7-zip.org/a/%s' % setup_filename_x86,setup_filename_x86) if not isfile(setup_filename_x64): wget('http://www.7-zip.org/a/%s' % setup_filename_x64,setup_filename_x64) for fn in glob.glob('7z*.msi'): if not fn in (setup_filename_x86,setup_filename_x64): remove_file(fn) update_control(control) def update_control(control): packaging = control.version.rsplit('-',1) if packaging: packaging = packaging[1] else: packaging = '0' control.version = product_version+'-'+packaging if __name__ == '__main__': control = PackageEntry() control.load_control_from_wapt('.') update_package(control) control.save_control_to_wapt('.')
Changelog
"""{% trans %}No changelog.{% endtrans %}"""
manifest.sha256
[["WAPT/icon.png", "3d79e3fb44d25506296abfd674a789945a165e3484cf1e12bbd05ff389b6bdb8"], ["WAPT/certificate.crt", "20f25d6b242159077345379865f8e0d84bdc9e4764190f1aa6cb3816bcabd341"], ["WAPT/wapt.psproj", "b26c073b8539e7d5e8ecc2b663bc5ecc30210ea639e056a319fe5f4658e6a20d"], ["7z1604-x64.msi", "b3885b2f090f1e9b5cf2b9f802b07fe88e472d70d60732db9f830209ac296067"], ["7z1604.msi", "d9b62c0ed0eb48d2df86d8b83394048414a2a4e1d64a50adb9abcff643471d20"], ["setup.py", "50b77e2da25b92297e92af8b861cab663541c14f30ce945f307ed26e467bcaa6"], ["WAPT/control", "62e80dbd897f2422c49c3f495006e9fa6f7995c69fbd47c132a7d54ef0207bb5"]]