tis-thunderbird 52.7.0-5

  • package : tis-thunderbird
  • version : 52.7.0-5
  • description : Client de messagerie email POP IMAP LDAP
  • maintainer : Simon Fonteneau
  • date : 2018-04-25 16:20:28

setup.py

#!/usr/bin/python
# -*- coding: utf-8 -*-

from setuphelpers import *


uninstallkey = []


#proxy={'http':'http://srvproxy:3128','https':'http://srvproxy:3128'}
proxy = {}

def install():
    version = control['version'].split('-',1)[0]
    key='Mozilla Thunderbird %s (x86 fr)' % version
    install_exe_if_needed('Thunderbird Setup %s.exe' % version ,silentflags='-ms',key=key ,min_version=version,killbefore=['thunderbird.exe'])
    remove_desktop_shortcut('Mozilla Thunderbird')


    print("Disabling auto update")
    filecopyto("mozilla.cfg",install_location(key))
    filecopyto("local-settings.js",makepath(install_location(key),"defaults","pref"))


def update_package():

    import re,requests,urlparse,glob

    url = requests.head('https://download.mozilla.org/?product=thunderbird-latest&os=win&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)
    else:
        print(filename + ' already exist')


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

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

    print('The update is complete, you can now test and then launch a build upload.')

if __name__ == '__main__':
    update_package()


    

Changelog

No changelog
    

manifest.sha256

[["local-settings.js", "78498a0d8c1e6b137e93081a785aacf63fccc3fb8f7ea04354d48224f5e1b357"], ["WAPT/icon.png", "4c42c4e3dc4d47449a18c238f73a5d41d589afd612c1d26ea53df46b00ed2425"], ["WAPT/certificate.crt", "79e5388683c0b6cb03f4f81e4e58e3a11463b2b6cf169dd9c453098027dcfaa4"], ["WAPT/wapt.psproj", "879fefa6dec88f4c0b40bc5cad2ed56484650a8f7a4eaaf2f36b2974c18e7e59"], ["Thunderbird Setup 52.7.0.exe", "c05a282c66eb608e8966af9374bdb95b04edd3a42c588f2136b53a63a6fdf462"], ["setup.py", "dec0939f6cceae2d290b80de46efc3cfe713bee01d8bc3aeca304e140cc175d5"], ["WAPT/control", "44b7a3b9747881ab836e6803149c7a73ef07a67df996b0abf9da6dd1b0d90dc7"], ["mozilla.cfg", "d9105efcd02b10b92a94166553e9f3c76dd9ea53115689744488701499db784a"]]