Tranquil IT recrute Tranquil IT recrute

tis-firefox

Version : 64.0-2

Download
  • package : tis-firefox
  • editor : Mozilla
  • version : 64.0-2
  • licence :
  • architecture : x64
  • locale : fr
  • description : Firefox Web Browser French
  • description_fr : Navigateur web Mozilla Firefox Français
  • min_os_version : 6.1
  • max_os_version :
  • min_wapt_version : 1.5
  • installed_size : 180727808
  • impacted_process : firefox.exe
  • signature_date : 20181212-103046
  • maintainer : Kevin Guerineau, TIS <technique@tranquil-it-systems.fr>
  • Conflicts :

setup.py

# -*- coding: UTF-8 -*-
from setuphelpers import *
import time

uninstallkey = []

def install():

    waptversion = Version(__version__)

    if waptversion > Version('1.5') :

        softname ='Mozilla Firefox'
        diskfreespacebefore = get_disk_free_space(programfiles)

        for uninstall in installed_softwares(softname):
            if 'x86' in uninstall['name']:
                if uninstall_key_exists(uninstall['key']):
                    killalltasks('firefox.exe')
                    cmd = WAPT.uninstall_cmd(uninstall['key'])
                    run(cmd)
                    time.sleep (5)

        for uninstall in installed_softwares(softname):
            if 'ESR' in uninstall['name']:
                if uninstall_key_exists(uninstall['key']):
                    killalltasks('firefox.exe')
                    cmd = WAPT.uninstall_cmd(uninstall['key'])
                    run(cmd)
                    time.sleep (5)

        version = control.version.split('-',1)[0]
        arch = control.architecture
        locale = control.locale
        ukey = 'Mozilla Firefox %s (%s %s)'%(version,arch,locale)
        exe = 'Firefox Setup %s.exe'%version
        install_exe_if_needed(exe,'-ms',key=ukey,min_version=version,killbefore='firefox.exe')

        for mms in installed_softwares('MozillaMaintenanceService'):
            if uninstall_key_exists(mms['key']):
                run(uninstall_cmd(mms['key']))

        diskfreespaceafter = get_disk_free_space(programfiles)

        difffreespace = diskfreespacebefore - diskfreespaceafter
        print (ur"Espace disque occupé :" + str(difffreespace))

    else:
        error('This package is not compatible with your WAPT version. Please upgrade to WAPT 1.5 or more.')




def update_package():
    """updates the package / control version with the latest stable firefox version"""
    import re,requests,urlparse,glob
    proxy = {'http':'http://srvproxy:3128','https':'http://srvproxy:3128'}
    #proxy = {}
    # get index of all dowloads
    """
    #url_base = 'https://download-installer.cdn.mozilla.net/pub/firefox/releases/latest/win32/fr/'
    url_base = 'https://download-installer.cdn.mozilla.net/pub/firefox/releases/43.0/win32/fr/'
    index = wgets(url_base)

    # get list of lastest french versions
    re_setup = re.compile(r'<a href=".*/(Firefox%20Setup%20[0-9.]*.exe)">Firefox Setup .*</a>')
    filename = urlparse.unquote(re_setup.findall(index)[0])
    url = url_base+filename
    """
    url = requests.head('https://download.mozilla.org/?product=firefox-latest-ssl&os=win64&lang=fr',proxies=proxy).headers['Location']
    filename = urlparse.unquote(url.rsplit('/',1)[1])

    if not isfile(filename):
        print('Downloading %s from %s'%(filename,url))
        wget(url,filename,proxies=proxy)

    # removes old exe
    if isfile(filename):
        exes = glob.glob('Firefox*.exe')
        for fn in exes:
            if fn != filename:
                remove_file(fn)

        # updates control version from filename, increment package version.
        control = PackageEntry().load_control_from_wapt ('.')
        control.version = '%s-%s'%(re.findall('Firefox Setup (.*)\.exe',filename)[0],int(control.version.split('-',1)[1])+1)
        control.save_control_to_wapt('.')


if __name__ == '__main__':
    update_package()

			

Changelog

"""{% trans %}No changelog.{% endtrans %}"""
			

manifest.sha256

[["WAPT/icon.png", "948e4bf2f1c1595091315354eb9fd9fb8f77d6675a2dd24337e35d9b7a4966a1"], ["WAPT/certificate.crt", "13fb474c5c23c135a77aba592eb8821b9ecbcc463f5b7312312b87b20eac6779"], ["WAPT/wapt.psproj", "df3e2fa87fea9c7bdfcc22039b9ef7303f092898882d9f3f4233f5d92f90b3c7"], ["Firefox Setup 64.0.exe", "86541290430061ca3ccc961bb98ec57a82a7e65d40e0c220719e4a86b1acf61c"], ["setup.py", "12849d779dad5f3de895a99b317dded0f3f06347a5ce6eaa70a0a809bc01aaab"], ["WAPT/control", "d52586649fa1c0c0c111c02b8d28fc6e81d38f5c7acd82e6819af955d7a8e9d4"]]