Skip to content

Commit

Permalink
Clean up installer (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
psalic authored Oct 11, 2024
1 parent 5fd2e01 commit eb9e799
Showing 1 changed file with 11 additions and 16 deletions.
27 changes: 11 additions & 16 deletions msys2_scripts/nsis_lxi-toolst.nsi
Original file line number Diff line number Diff line change
Expand Up @@ -8,21 +8,26 @@
!define MUI_ICON "..\lxi-tools\build\src\lxi-tools.ico"
!define MUI_UNICON "..\lxi-tools\build\src\lxi-tools.ico"

Name "${COMPANYNAME} - ${APPNAME}"
Name "${APPNAME}"

Icon "..\lxi-tools\build\src\lxi-tools.ico"

Outfile "lxi-tools-$%BUILD_VERSION%.exe"

InstallDir "C:\Program Files\${COMPANYNAME}"

!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_LICENSE "${LicenseFile}"
!insertmacro MUI_LANGUAGE "English"
!insertmacro MUI_PAGE_DIRECTORY
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_PAGE_FINISH

!insertmacro MUI_UNPAGE_WELCOME
!insertmacro MUI_UNPAGE_CONFIRM
!insertmacro MUI_UNPAGE_INSTFILES
!insertmacro MUI_UNPAGE_FINISH

page directory
Page instfiles
UninstPage uninstConfirm
UninstPage instfiles
!insertmacro MUI_LANGUAGE "English"

# start default section
Section "install"
Expand Down Expand Up @@ -65,19 +70,9 @@ Section "install"
Delete $TEMP\lxi-tools.ico
SectionEnd

function un.onInit
# SetShellVarContext all

#Verify the uninstaller - last chance to back out
MessageBox MB_OKCANCEL "Are you sure you want to remove Lxi Tools?" IDOK next
Abort
next:
functionEnd

# uninstaller section start
Section "uninstall"
# SetShellVarContext all

rmDir /r "$SMPROGRAMS\${COMPANYNAME}"
rmDir /r "$INSTDIR"

Expand Down

0 comments on commit eb9e799

Please sign in to comment.