Debian Codegraph @

Contrib/InstallOptions/testlink.nsi

raw
1 ;InstallOptions Test Script
2 ;Written by Ramon
3 ;This script demonstrates the power of the new control "LINK"
4 ;that allows you to execute files, send mails, open wepsites, etc.
5 ;--------------------------
6
7 !define TEMP1 $R0 ;Temp variable
8
9 ;The name of the installer
10 Name "InstallOptions Test Link"
11
12 ;The file to write
13 OutFile "TestLink.exe"
14
15 ; Show install details
16 ShowInstDetails show
17
18 ;Things that need to be extracted on startup (keep these lines before any File command!)
19 ;Only useful for BZIP2 compression
20 ;Use ReserveFile for your own InstallOptions INI files too!
21
22 ReserveFile /plugin InstallOptions.dll
23 ReserveFile "testlink.ini"
24
25 ;Order of pages
26 Page custom SetCustom
27 Page instfiles
28
29 Section "Components"
30
31 ;Get Install Options dialog user input
32
33 SectionEnd
34
35 Function .onInit
36
37 ;Extract InstallOptions files
38 ;$PLUGINSDIR will automatically be removed when the installer closes
39
40 InitPluginsDir
41 File /oname=$PLUGINSDIR\test.ini "testlink.ini"
42 WriteIniStr $PLUGINSDIR\test.ini "Field 2" "State" "$WINDIR\Notepad.exe"
43
44 FunctionEnd
45
46 Function SetCustom
47
48 ;Display the InstallOptions dialog
49
50 Push ${TEMP1}
51
52 InstallOptions::dialog "$PLUGINSDIR\test.ini"
53 Pop ${TEMP1}
54
55 Pop ${TEMP1}
56
57 FunctionEnd
58