tis-googleearth 7.3.0.3832-1

  • package : tis-googleearth
  • version : 7.3.0.3832-1
  • description : Google Earth for Windows
  • maintainer : Tranquil it systems
  • date : 2017-09-13 10:19:12
  • signer : TRANQUIL IT SYSTEMS
  • signature_date : 20170913-101911
  • min_os_version :
  • min_wapt_version :

setup.py

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

from setuphelpers import *

uninstallkey=[]

def install():
    install_msi_if_needed('GoogleEarthSetup.msi',killbefore=['googleearth.exe'])
    remove_desktop_shortcut('Google Earth')



def update_package():

    wget('https://dl.google.com/tag/s/appguid%3D%7B74AF07D8-FB8F-4d51-8AC7-927721D56EBB%7D%26iid%3D%7B78F4DCC2-2356-1949-3E7D-CA58A34BA41F%7D%26lang%3Dfr%26browser%3D3%26usagestats%3D0%26appname%3DGoogle%2520Earth%26needsadmin%3DTrue%26brand%3DGGGE/earth/client/GoogleEarthSetup.exe','GoogleEarthSetup.exe')
    run('GoogleEarthSetup.exe')
    killalltasks('googleearth.exe')

    for uninstall in installed_softwares('Google Earth'):
        vers = uninstall['version']
        print vers

    #Search msi and copy msi file if version is good
    remove_file('GoogleEarthSetup.exe')
    with disable_file_system_redirection():
        for msi in glob.glob(r'C:\Windows\Installer\*.msi'):
            if get_msi_properties(msi)['ProductName'] == 'Google Earth Pro':
                if  Version(get_msi_properties(msi)['ProductVersion']) == Version(vers):
                        remove_file('GoogleEarthSetup.msi')
                        filecopyto(msi,'GoogleEarthSetup.msi')




    # change version of package
    from waptpackage import PackageEntry
    pe = PackageEntry()
    pe.load_control_from_wapt(os.getcwd())
    pe.version = get_msi_properties('GoogleEarthSetup.msi')['ProductVersion'] +'-0'
    pe.save_control_to_wapt(os.getcwd())




if __name__ == '__main__':
    update_package()
    

manifest

[["WAPT/icon.png", "068bce118ecb610adfd47be9429999528b5f7664"], ["WAPT/certificate.crt", "0db563dc9077b268ca07ba834322d0fc5e21f8e5"], ["WAPT/wapt.psproj", "7ccbe65afd42ee7794a86ed74eef48e3f5812c93"], ["GoogleEarthSetup.msi", "c988395b38dbde83efeff16bc4cc2d1608fbb091"], ["setup.py", "e1b9e9d2ee21d6e5c5c94ab550e7c06b5609311e"], ["WAPT/control", "df162c0106b172a59478ce6e9c876a6521b07ed6"]]