anotherim-desktop/windows-installer/dino.nsi

81 lines
2 KiB
Plaintext
Raw Normal View History

Unicode True
!define MUI_PRODUCT "Dino"
!define MUI_PRODUCT_NAME ${MUI_PRODUCT}
2020-05-05 17:17:45 +00:00
!define MUI_BRANDINGTEXT ${MUI_PRODUCT}
!define PRODUCT_WEBSITE "https://dino.im"
!define MUI_ICON "input/logo.ico"
!define ICON "input/logo.ico"
!define MUI_COMPONENTSPAGE_NODESC
# Installation types
InstType "OpenPGP support" IT_PGP
2020-05-05 17:17:45 +00:00
# Modern Interface
!include "MUI2.nsh"
!insertmacro MUI_PAGE_LICENSE "input/LICENSE_SHORT"
!insertmacro MUI_PAGE_COMPONENTS
2020-05-05 17:17:45 +00:00
!insertmacro MUI_PAGE_INSTFILES
2020-06-28 05:13:52 +00:00
!include "english.nsh"
!include "german.nsh"
2020-05-05 17:17:45 +00:00
Name ${MUI_PRODUCT}
BrandingText "Communicating happiness"
# define installer name
OutFile "dino-installer.exe"
# set install directory
InstallDir $PROGRAMFILES64\dino
2020-06-28 05:13:52 +00:00
Section
# Install all files but openpgp.dll
SetOutPath $INSTDIR
File /r input/bin
File input/LICENSE
File input/logo.ico
File input/logo.svg
File /r input/share
SetOutPath $INSTDIR\lib
File /r input/lib/gio
File /r input/lib/gdk-pixbuf-2.0
SetOutPath $INSTDIR\lib\dino\plugins
File input/lib/dino/plugins/http-files.dll
File input/lib/dino/plugins/omemo.dll
File input/lib/dino/plugins/win32-fonts.dll
# define uninstaller name
WriteUninstaller $INSTDIR\uninstaller.exe
# Create a shortcut for startmenu
CreateDirectory "$SMPROGRAMS\Dino"
CreateShortcut "$SMPROGRAMS\Dino\Dino.lnk" "$INSTDIR\bin\dino.exe" "" "$INSTDIR\logo.ico"
CreateShortcut "$SMPROGRAMS\Dino\Uninstaller.lnk" "$INSTDIR\uninstaller.exe"
CreateShortcut "$SMPROGRAMS\Dino\License.lnk" "$INSTDIR\LICENSE" "" "notepad.exe" 0
CreateShortcut "$SMPROGRAMS\Dino\Dino website.lnk" "https://dino.im" "" "$INSTDIR\logo.ico"
SectionEnd
Section "OpenPGP support"
SectionInstType ${IT_PGP}
SetOutPath $INSTDIR/lib/dino/plugins
File input/lib/dino/plugins/openpgp.dll
SectionEnd
# Uninstaller section
Section "Uninstall"
# Delete startmenu folder
RMDir /r "$SMPROGRAMS\Dino"
# Always delete uninstaller first
Delete $INSTDIR\uninstaller.exe
# now delete installed file
Delete $INSTDIR\*
# Delete the directory
RMDir /r $INSTDIR
SectionEnd