tis-dotnet5 icon

.NET Desktop Runtime 5

Paquet d’installation silencieuse pour .NET Desktop Runtime 5

5.0.17-5

  • package: tis-dotnet5
  • name: .NET Desktop Runtime 5
  • version: 5.0.17-5
  • categories: Dependency
  • maintainer: WAPT Team,Tranquil IT,Pierre Cosson,Jimmy PELÉ
  • editor: Microsoft
  • licence: MIT License
  • locale: all
  • target_os: windows
  • architecture: x86
  • signature_date:
  • size: 49.50 Mo
  • installed_size: 320.91 Mo
  • homepage : https://github.com/dotnet/runtime

package           : tis-dotnet5
version           : 5.0.17-5
architecture      : x86
section           : base
priority          : optional
name              : .NET Desktop Runtime 5
categories        : Dependency
maintainer        : WAPT Team,Tranquil IT,Pierre Cosson,Jimmy PELÉ
description       : The .NET Desktop Runtime enables you to run existing Windows desktop applications. This release includes the .NET Runtime; you don't need to install it separately
depends           : 
conflicts         : 
maturity          : PROD
locale            : all
target_os         : windows
min_wapt_version  : 2.0
sources           : https://github.com/dotnet/runtime
installed_size    : 320911360
impacted_process  : 
description_fr    : Le .NET Desktop Runtime vous permet d'exécuter des applications de bureau Windows existantes. Cette version inclut le moteur d'exécution .NET ; vous n'avez pas besoin de l'installer séparément
description_pl    : Program .NET Desktop Runtime umożliwia uruchamianie istniejących aplikacji desktopowych Windows. To wydanie zawiera .NET Runtime; nie trzeba go instalować osobno
description_de    : Mit der .NET Desktop Runtime können Sie vorhandene Windows-Desktop-Anwendungen ausführen. Diese Version enthält die .NET Runtime; Sie brauchen sie nicht separat zu installieren
description_es    : El Desktop Runtime de .NET le permite ejecutar las aplicaciones de escritorio de Windows existentes. Esta versión incluye el .NET Runtime; no es necesario instalarlo por separado
description_pt    : O .NET Desktop Runtime permite-lhe executar as aplicações de ambiente de trabalho Windows existentes. Esta versão inclui o .NET Runtime; não é necessário instalá-lo separadamente
description_it    : Il .NET Desktop Runtime consente di eseguire le applicazioni desktop di Windows esistenti. Questa versione include il .NET Runtime; non è necessario installarlo separatamente
description_nl    : Met de .NET Desktop Runtime kunt u bestaande Windows-desktoptoepassingen uitvoeren. Deze release bevat de .NET Runtime; u hoeft deze niet apart te installeren
description_ru    : .NET Desktop Runtime позволяет запускать существующие настольные приложения Windows. Этот выпуск включает .NET Runtime; вам не нужно устанавливать его отдельно
audit_schedule    : 
editor            : Microsoft
keywords          : 
licence           : MIT License
homepage          : https://github.com/dotnet/runtime
package_uuid      : f95a3206-297c-46d7-8811-ee5ad73a009e
valid_from        : 
valid_until       : 
forced_install_on : 
changelog         : https://github.com/dotnet/core/tree/main/release-notes/5.0
min_os_version    : 6.1
max_os_version    : 
icon_sha256sum    : 1460db9c3885967269ebbc71d898181ab7d1506f3212bafc2df3acc648d43db0
signer            : Tranquil IT
signer_fingerprint: 8c5127a75392be9cc9afd0dbae1222a673072c308c14d88ab246e23832e8c6bb
signature         : e041lTlUYf6XlOnz/Ov6jDi9sLc+v4bh9Md32PLMSze56HTnvIpMbPTQ5ULwv4rSdzchhiY1NOxP1znCuKmo0wzd5SIdaBT/E4HAaqsC+i+FOmbd7bYLgDfx7ClEHqo9wPSOpw9MQ8uTRxogaAP51vUPnrc+zLBSbVjbvB35J3RetzI+KpJLClATKJX1JvGfsol2K/ZRT5Dq70XGVzwvoN51uEZzAA5svBUqowaby1jEZT+GjCFmG8WhwJckE0AbI99X1ImTKX6RWhQMRCQIxed5wEFm7HiGRduPXmF16iFh+AKuP/aDtxp/yOQOTRf9s0s3Hxogi44y+842Y1Mf6w==
signature_date    : 2022-08-02T03:45:13.821629
signed_attributes : package,version,architecture,section,priority,name,categories,maintainer,description,depends,conflicts,maturity,locale,target_os,min_wapt_version,sources,installed_size,impacted_process,description_fr,description_pl,description_de,description_es,description_pt,description_it,description_nl,description_ru,audit_schedule,editor,keywords,licence,homepage,package_uuid,valid_from,valid_until,forced_install_on,changelog,min_os_version,max_os_version,icon_sha256sum,signer,signer_fingerprint,signature_date,signed_attributes

# -*- coding: utf-8 -*-
from setuphelpers import *

r"""
Usable WAPT package functions: install(), uninstall(), session_setup(), audit(), update_package()

PS C:\waptdev-testing\dotnet5> wapt-get list-registry "Microsoft - 5."
Using config file: C:\Program Files (x86)\wapt\wapt-get.ini
UninstallKey                           Software                                                              Version             Uninstallstring
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
{4CD6FFC6-FA14-4016-A7A6-B7E3D6286331} Microsoft Windows Desktop Runtime - 5.0.14 (x64)                      40.56.30911         MsiExec.exe /X{4CD6FFC6-FA14-4016-A7A6-B7E3D6286331}
{61A6E3A7-F406-418A-B2A6-0606DB55B325} Microsoft .NET Host - 5.0.14 (x64)                                    40.56.30907         MsiExec.exe /X{61A6E3A7-F406-418A-B2A6-0606DB55B325}
{8D88F0E2-CE9B-4A6D-8309-FDC562195F5B} Microsoft .NET Host FX Resolver - 5.0.14 (x64)                        40.56.30907         MsiExec.exe /X{8D88F0E2-CE9B-4A6D-8309-FDC562195F5B}
{B810ACDF-1C0C-4108-9B92-12F1674FA444} Microsoft .NET Runtime - 5.0.14 (x64)                                 40.56.30907         MsiExec.exe /X{B810ACDF-1C0C-4108-9B92-12F1674FA444}
{3F927D21-88CF-4113-87C4-7F5D90ACFD5C} Microsoft Windows Desktop Runtime - 5.0.14 (x86)                      40.56.30911         MsiExec.exe /X{3F927D21-88CF-4113-87C4-7F5D90ACFD5C}
{572247F8-D39E-4F09-B2E3-886F464DB5A6} Microsoft .NET Host - 5.0.14 (x86)                                    40.56.30907         MsiExec.exe /X{572247F8-D39E-4F09-B2E3-886F464DB5A6}
{64E80A14-A4CE-4209-9E96-E3B33957FE7C} Microsoft .NET Host FX Resolver - 5.0.14 (x86)                        40.56.30907         MsiExec.exe /X{64E80A14-A4CE-4209-9E96-E3B33957FE7C}
{6c41e020-a684-4c42-95de-f3634a7747ec} Microsoft Windows Desktop Runtime - 5.0.14 (x86)                      5.0.14.30911        "C:\ProgramData\Package Cache\{6c41e020-a684-4c42-95de-f3634a7747ec}\windowsdesktop-runtime-5.0.14-win-x86.exe"  /uninstall
{B53264E4-665F-4F04-BF0C-7F9C9B7A5640} Microsoft .NET Runtime - 5.0.14 (x86)                                 40.56.30907         MsiExec.exe /X{B53264E4-665F-4F04-BF0C-7F9C9B7A5640}
{d21a4f20-968a-4b0c-bf04-a38da5f06e41} Microsoft Windows Desktop Runtime - 5.0.14 (x64)                      5.0.14.30911        "C:\ProgramData\Package Cache\{d21a4f20-968a-4b0c-bf04-a38da5f06e41}\windowsdesktop-runtime-5.0.14-win-x64.exe"  /uninstall

"""
# Declaring global variables - Warnings: 1) WAPT context is only available in package functions; 2) Global variables are not persistent between calls
bin_contains = "windowsdesktop-runtime-"
# app_uninstallkey_x64 = "{1a728e82-3f40-4727-a130-218513758946}"
# app_uninstallkey_x86 = "{e37b6a90-60df-4744-92b5-f12059e0167d}"
app_silentflags = "/install /quiet /norestart"


def install():
    # Declaring local variables
    package_version = control.get_software_version()
    dotnet_version = package_version.split(".")[0]

    # Checking if the same or a newer version is already present
    for installed_version in installed_softwares(name="Microsoft .* Runtime - %s.*" % dotnet_version):
        if Version(installed_version["version"], 1) == Version(package_version, 1):
            if Version(installed_version["version"]) < Version(package_version):
                force = True

    # Installing the x86 software
    if not iswin64() or control.architecture == "all":
        bin_name_x86 = glob.glob("*%s*x86.exe" % bin_contains)[0]
        print("Installing: %s" % bin_name_x86)
        install_exe_if_needed(
            bin_name_x86,
            silentflags=app_silentflags,
            name="Microsoft Windows Desktop Runtime - %s.*(x86)" % dotnet_version,
            min_version="",
        )

    if iswin64():
        # Installing the x64 software
        bin_name_x64 = glob.glob("*%s*x64.exe" % bin_contains)[0]
        print("Installing: %s" % bin_name_x64)
        install_exe_if_needed(
            bin_name_x64,
            silentflags=app_silentflags,
            name="Microsoft Windows Desktop Runtime - %s.*(x64)" % dotnet_version,
            min_version="",
        )

    # Adding needed UninstallKeys as install_exe retrieve unreliable keys
    uninstallkey.clear()
    for installed_version in installed_softwares(name="Microsoft .* Runtime - %s.*" % dotnet_version):
        if Version(installed_version["version"], 1) == Version(package_version, 1):
            uninstallkey.append(installed_version["key"])


def update_package():
    # Declaring local variables
    package_version = control.get_software_version()
    dotnet_version = ".".join(package_version.split(".")[:2])
    result = False
    proxies = get_proxies()
    if control.architecture != "all":
        archs = [control.architecture]
    else:
        archs = ["x86", "x64"]

    if not proxies:
        proxies = get_proxies_from_wapt_console()
    app_name = control.name

    for arch in archs:
        url_version = "https://versionsof.net/core/%s/" % dotnet_version
        version = wgets(url_version, proxies=proxies).split("Latest runtime:")[1].split("/")[3]
        url = "https://versionsof.net/core/%s/%s/" % (dotnet_version, version)

        # Getting latest version from official sources
        print("URL used is: %s" % url)
        for bs_search in bs_find_all(url, "a", proxies=proxies, timeout=10):
            if bin_contains in bs_search["href"] and arch in bs_search["href"]:
                latest_bin = bs_search["href"].split("/")[-1]
                download_url = bs_search["href"]
                break

        print("Latest %s version is: %s" % (app_name, version))
        print("Download URL is: %s" % download_url)

        # Downloading latest binaries
        if not isfile(latest_bin):
            print("Downloading: %s" % latest_bin)
            wget(download_url, latest_bin, proxies=proxies)

            # Checking version from file
            version_from_file = get_version_from_binary(latest_bin)
            if not version_from_file.startswith(version) and version_from_file != "":
                print("Changing version to the version number of the binary (from: %s to: %s)" % (version, version_from_file))
                os.rename(latest_bin, bin_contains + version_from_file + "-%s.exe" % arch)
                version = version_from_file
            else:
                print("Binary file version corresponds to online version")

    # Changing version of the package
    if Version(version) > Version(control.get_software_version()):
        print("Software version updated (from: %s to: %s)" % (control.get_software_version(), Version(version)))
        result = True
    else:
        print("Software version up-to-date (%s)" % Version(version))
    control.version = "%s-%s" % (Version(version), control.version.split("-", 1)[-1])
    # control.set_software_version(version)
    control.save_control_to_wapt()

    # Deleting outdated binaries
    remove_outdated_binaries(version)

    # Validating or not update-package-sources
    return result

e55dd3d7fdc554fe936854e81fbfdeb1e9669dabdc3b63feb2fe40a8e2baa5c6 : setup.py
1460db9c3885967269ebbc71d898181ab7d1506f3212bafc2df3acc648d43db0 : WAPT/icon.png
a5a97261381e1d0ad46ee15916abec9c2631d0201f5cc50ceb0197a165a0bbbf : WAPT/certificate.crt
56766b7a268d070341c5098fd35bfdddd6863e6bfe443089fce48846e6434e1d : luti.json
63fef76824c51df09ed6fc5b031796fad64435db0e72f1735021b55760360c98 : windowsdesktop-runtime-5.0.17-win-x86.exe
d6cefa1712492f593f42c242953a7aa6679fcde5b6ef1c0c7a767c1caac69f24 : WAPT/control