tis-foxit5 5.3.1.606-17

  • package : tis-foxit5
  • version : 5.3.1.606-17
  • description : PDF reader
  • maintainer : TIS <technique@tranquil-it-systems.fr>
  • date : 2018-02-27 19:00:05

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/>.
#
# -----------------------------------------------------------------------
import platform
from setuphelpers import *

required_params = []
uninstallstring=''
uninstallkey=['{27E3028E-06C8-4C09-8C3E-07F7F508304E}']

destdir = makepath(programfiles32,'Foxit Software','Foxit Reader')

def install():
    print "Check if one or several old version of Foxit are installed"
    all_foxit = installed_softwares('foxit reader')
    if all_foxit:
        for foxit in all_foxit:
            if foxit['version'] <> '5.3.1.606':
                print "Uninstall %s (%s)" % (foxit['name'],foxit['version'])
                run(WAPT.uninstall_cmd(foxit['key']))

    all_foxit = installed_softwares('foxit reader')
    if not all_foxit or WAPT.options.force:
        print("installing foxit reader")
        print run('msiexec /qn /I FoxitReader531.0606_enu.msi DESKTOP_SHORTCUT="0" MAKEDEFAULT="1" VIEWINBROWSER="0" /passive /norestart  /qn')
    else:
        print "Foxit already installed, skipping installation"

    print "Post installation"
    lang = makepath(destdir,'lang')
    if not isdir(lang):
	    os.makedirs(lang)
    filecopyto('lang_fr_fr.xml',makepath(lang,'lang_fr_fr.xml'))
    # Keep a copy of user default files.
    filecopyto('userpref.reg',destdir)
    filecopyto('french.reg',destdir)
    session_setup()

def session_setup():
    run('reg IMPORT "%s"' % makepath(destdir,'userpref.reg'))
    run('reg IMPORT "%s"' % makepath(destdir,'french.reg'))

    

Changelog

No changelog
    

manifest.sha256

[["WAPT/certificate.crt", "79e5388683c0b6cb03f4f81e4e58e3a11463b2b6cf169dd9c453098027dcfaa4"], ["lang_fr_fr.xml", "ea38fe12c94f51cb9f5a5857620404b5b7c731739f1b243bb94433ceed1c7aa8"], ["userpref.reg", "e77a380e6ebb8f7412801c01f30acb4f633449ba9df3a9270bcfa56240d45b9d"], ["WAPT/tis-foxit.psproj", "063bb75e5221c030313019fa37d11bb31b313bc5bf16940e6760d0abbb8b9c7c"], ["french.reg", "c2d5ca03442e9ecbcbe0ecca13dd4e0edafff067812e1c4b8a2abbf796f74307"], ["FoxitReader531.0606_enu.msi", "56a67a29f3d31dfb2fd1f04ce7cf8dfb1ad62204c39399a936483eb35c1ae237"], ["setup.py", "39ee32491283f55262adbbd75db40bc35165a992c8c13266893a80339ec52cac"], ["WAPT/control", "a25991a9a748a2add8d45c7adbbb0d3ebf44e971d74fb53aa9ffa2c20a9d1fc5"], ["WAPT/wapt.psproj", "bc34bb5f85d78dffc7effd37bd0639580a0e140c155973c04d79eb9aa31eb57a"]]