Files
winehelper/testinstall/soun
2025-10-25 12:26:42 +06:00

27 lines
1.2 KiB
Bash
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#!/usr/bin/env bash
# info_ru: Справочник кодов обозначения налоговых органов для целей учета налогоплательщиков
########################################################################
export PROG_URL="https://www.nalog.gov.ru"
export WH_WINE_USE="wine_x_tkg_10-0_amd64"
export WINEPREFIX="nalog"
export PROG_NAME="СОУН"
export PROG_ICON="soun"
export BASE_PFX="none"
export WINEARCH="win32"
export WH_WINDOWS_VER="10"
export INSTALL_DLL="corefonts micross tahoma lucida riched20 comctl32 msxml3 msxml4 msxml6 mdac28 wsh57 vcrun6 vb6run jet40 gdiplus vcrun2019 dotnet20sp2 dotnet40 dotnet48"
try_get_page "https://www.nalog.gov.ru/rn77/program/5961268/"
VER_MSI_SLASH=$(read_page | grep -oP 'href="\K[^"]*.exe[^"]*' | awk -F'/' '{print $(NF-1)}' | head -n 1)
AUTOINSTALL_EXE="${WH_TMP_DIR}/soun_ins.exe"
prepair_wine
if try_download "https://data.nalog.ru/files/Soun/${VER_MSI_SLASH}/soun_ins.exe" "${AUTOINSTALL_EXE}" ; then
# TODO: Тихий режим или предупреждение
wine_run_install "${AUTOINSTALL_EXE}"
try_remove_file "${AUTOINSTALL_EXE}"
WIN_FILE_EXEC="$DRIVE_C/СОУН/SOUN.EXE"
create_desktop "$PROG_NAME" "$WIN_FILE_EXEC" "$PROG_ICON"
fi