2 iDmc Nullsoft Scriptable Install System
2 script for Windoze
.
3 Written by Daniele Pizzoni
<auouo@tin
.it
>
6 ; HM NIS Edit Wizard helper defines
7 !define APP_NAME
"iDmc"
8 !define APP_VERSION
"0.17.4"
9 !define LIB_VERSION
"0.14.1"
11 ; MUI 1.67 compatible ------
15 !define MUI_ABORTWARNING
16 !define MUI_ICON
"${NSISDIR}\Contrib\Graphics\Icons\modern-install.ico"
17 !define MUI_UNICON
"${NSISDIR}\Contrib\Graphics\Icons\modern-uninstall.ico"
20 !insertmacro MUI_PAGE_WELCOME
22 !insertmacro MUI_PAGE_LICENSE
"README"
24 !insertmacro MUI_PAGE_DIRECTORY
26 !insertmacro MUI_PAGE_INSTFILES
28 !insertmacro MUI_PAGE_FINISH
31 !insertmacro MUI_UNPAGE_INSTFILES
34 !insertmacro MUI_LANGUAGE
"English"
38 !define APP_FULLNAME
"${APP_NAME}-${APP_VERSION}"
39 !define LIB_FULLNAME
"${APP_NAME}-${LIB_VERSION}"
40 !define FILE_JAR
"${APP_FULLNAME}.jar"
41 !define FILE_DLL
"${LIB_FULLNAME}.dll"
42 !define DIR_MODELS
"$INSTDIR\models"
45 Name "${APP_FULLNAME}"
46 OutFile "${APP_FULLNAME}-setup.exe"
47 InstallDir "$PROGRAMFILES\${APP_FULLNAME}"
49 ShowUnInstDetails show
53 Section "Executables" SEC01
63 Section "Models" SEC02
64 SetOutPath "${DIR_MODELS}"
67 File "models\cremona.lua"
68 File "models\ctbif.lua"
69 File "models\ctlocal.lua"
70 File "models\gingerman.lua"
71 File "models\henon.lua"
72 File "models\henon2.lua"
73 File "models\hopf.lua"
74 File "models\ikeda.lua"
75 File "models\logist.lua"
76 File "models\lorenz.lua"
78 File "models\nordmark.lua"
80 File "models\quasi.lua"
81 File "models\quasiperiodicity.lua"
82 File "models\rossler.lua"
83 File "models\rotor.lua"
84 File "models\silnikov2.lua"
85 File "models\standard.lua"
86 File "models\tent.lua"
87 File "models\tinkerbell.lua"
92 CreateDirectory "$SMPROGRAMS\${APP_FULLNAME}"
93 CreateShortCut "$SMPROGRAMS\${APP_FULLNAME}\${APP_FULLNAME}.lnk" "$INSTDIR\${FILE_JAR}" -library=
"$INSTDIR\${FILE_DLL}"
94 CreateShortCut "$DESKTOP\${APP_FULLNAME}.lnk" "$INSTDIR\${FILE_JAR}" -library=
"$INSTDIR\${FILE_DLL}"
95 # CreateShortCut "$DESKTOP\iDmc models.lnk" "${DIR_MODELS}"
96 CreateShortCut "$SMPROGRAMS\${APP_FULLNAME}\Uninstall.lnk" "$INSTDIR\uninst.exe"
100 WriteUninstaller "$INSTDIR\uninst.exe"
101 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APP_FULLNAME}" "DisplayName" "$(^Name)"
102 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APP_FULLNAME}" "UninstallString" "$INSTDIR\uninst.exe"
103 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APP_FULLNAME}" "DisplayVersion" "${APP_VERSION}"
104 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APP_FULLNAME}" "Publisher" "TshoSoft"
105 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APP_FULLNAME}" "InstallLocation" "$INSTDIR"
109 Function un
.onUninstSuccess
111 MessageBox MB_ICONINFORMATION|
MB_OK "${APP_FULLNAME} was successfully removed from your computer."
115 MessageBox MB_ICONQUESTION|
MB_YESNO|MB_DEFBUTTON2
"Are you sure you want to completely remove ${APP_FULLNAME} and all of its components?" IDYES +2
120 Delete "$INSTDIR\uninst.exe"
122 Delete "${DIR_MODELS}\cremona.lua"
123 Delete "${DIR_MODELS}\ctbif.lua"
124 Delete "${DIR_MODELS}\ctlocal.lua"
125 Delete "${DIR_MODELS}\gingerman.lua"
126 Delete "${DIR_MODELS}\henon.lua"
127 Delete "${DIR_MODELS}\henon2.lua"
128 Delete "${DIR_MODELS}\hopf.lua"
129 Delete "${DIR_MODELS}\ikeda.lua"
130 Delete "${DIR_MODELS}\logist.lua"
131 Delete "${DIR_MODELS}\lorenz.lua"
132 Delete "${DIR_MODELS}\lv.lua"
133 Delete "${DIR_MODELS}\nordmark.lua"
134 Delete "${DIR_MODELS}\par.lua"
135 Delete "${DIR_MODELS}\quasi.lua"
136 Delete "${DIR_MODELS}\quasiperiodicity.lua"
137 Delete "${DIR_MODELS}\rossler.lua"
138 Delete "${DIR_MODELS}\rotor.lua"
139 Delete "${DIR_MODELS}\silnikov2.lua"
140 Delete "${DIR_MODELS}\standard.lua"
141 Delete "${DIR_MODELS}\tent.lua"
142 Delete "${DIR_MODELS}\tinkerbell.lua"
144 RmDir
"${DIR_MODELS}"
146 Delete "$INSTDIR\${FILE_DLL}"
147 Delete "$INSTDIR\${FILE_JAR}"
149 Delete "$SMPROGRAMS\${APP_FULLNAME}\Uninstall.lnk"
150 Delete "$SMPROGRAMS\${APP_FULLNAME}\${APP_FULLNAME}.lnk"
151 Delete "$DESKTOP\${APP_FULLNAME}.lnk"
152 # Delete "$DESKTOP\iDmc models.lnk"
157 RMDir "$SMPROGRAMS\${APP_FULLNAME}"
160 DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${APP_FULLNAME}"