2 Commits
Author SHA1 Message Date
m4xx1m e4ee58ba88 chore(release): bump version to v2.1.2
Build Windows Installer / build (push) Successful in 9m10s
2026-11-13 02:15:35 +03:00
m4xx1m 4a069eecd2 fix(installer): add on-demand UAC elevation check for protected target directories 2026-11-13 02:14:13 +03:00
2 changed files with 33 additions and 2 deletions

No files matched your search

+32 -1
View File
@@ -2,7 +2,7 @@ Unicode True
!include "MUI2.nsh" !include "MUI2.nsh"
!ifndef VERSION !ifndef VERSION
!define VERSION "2.1.1" !define VERSION "2.1.2"
!endif !endif
!define APP_NAME "ConvertGUI" !define APP_NAME "ConvertGUI"
@@ -23,6 +23,7 @@ SetOverwrite on
!insertmacro MUI_PAGE_WELCOME !insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_COMPONENTS !insertmacro MUI_PAGE_COMPONENTS
!define MUI_PAGE_CUSTOMFUNCTION_LEAVE DirectoryLeave
!insertmacro MUI_PAGE_DIRECTORY !insertmacro MUI_PAGE_DIRECTORY
!insertmacro MUI_PAGE_INSTFILES !insertmacro MUI_PAGE_INSTFILES
!define MUI_FINISHPAGE_RUN "$INSTDIR\${EXE_NAME}" !define MUI_FINISHPAGE_RUN "$INSTDIR\${EXE_NAME}"
@@ -107,6 +108,36 @@ LangString DESC_DESKTOP ${LANG_ENGLISH} "Create a shortcut on the Desktop."
LangString DESC_DESKTOP ${LANG_RUSSIAN} "Создать ярлык на Рабочем столе." LangString DESC_DESKTOP ${LANG_RUSSIAN} "Создать ярлык на Рабочем столе."
LangString MSG_RUNNING ${LANG_ENGLISH} "${APP_NAME} is currently running.$\r$\n$\r$\nClick OK to close it and proceed with the update, or Cancel to abort." LangString MSG_RUNNING ${LANG_ENGLISH} "${APP_NAME} is currently running.$\r$\n$\r$\nClick OK to close it and proceed with the update, or Cancel to abort."
LangString MSG_RUNNING ${LANG_RUSSIAN} "Приложение ${APP_NAME} сейчас запущено.$\r$\n$\r$\nНажмите ОК, чтобы закрыть его и продолжить обновление, или Отмена для выхода." LangString MSG_RUNNING ${LANG_RUSSIAN} "Приложение ${APP_NAME} сейчас запущено.$\r$\n$\r$\nНажмите ОК, чтобы закрыть его и продолжить обновление, или Отмена для выхода."
LangString MSG_ADMIN_REQ ${LANG_ENGLISH} "Administrator privileges are required to install into:$\r$\n$INSTDIR$\r$\n$\r$\nRestart installer with administrator privileges?"
LangString MSG_ADMIN_REQ ${LANG_RUSSIAN} "Для установки в выбранную папку требуются права администратора:$\r$\n$INSTDIR$\r$\n$\r$\nПерезапустить установку от имени администратора?"
Function DirectoryLeave
ClearErrors
UserInfo::GetAccountType
Pop $0
StrCmp $0 "Admin" can_write 0
CreateDirectory "$INSTDIR"
FileOpen $0 "$INSTDIR\.write_test" w
IfErrors need_admin
FileClose $0
Delete "$INSTDIR\.write_test"
Goto can_write
need_admin:
ClearErrors
MessageBox MB_YESNO|MB_ICONQUESTION $(MSG_ADMIN_REQ) IDYES do_elevate IDNO stay_here
do_elevate:
ExecShell "runas" "$EXEPATH" '/D=$INSTDIR'
Quit
stay_here:
Abort
can_write:
FunctionEnd
Function .onInit Function .onInit
check_running: check_running:
+1 -1
View File
@@ -12,7 +12,7 @@ import (
) )
// Version is injected at build time via -ldflags "-X main.Version=..." // Version is injected at build time via -ldflags "-X main.Version=..."
var Version = "2.1.1-dev" var Version = "2.1.2-dev"
//go:embed all:frontend/dist //go:embed all:frontend/dist
var assets embed.FS var assets embed.FS