-
Notifications
You must be signed in to change notification settings - Fork 0
/
bncert-auto-updater.xml
53 lines (53 loc) · 2.57 KB
/
bncert-auto-updater.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<autoUpdateProject>
<fullName>bncert autoupdater</fullName>
<shortName>bncertupdater</shortName>
<version>1.0</version>
<enableSslSupport>1</enableSslSupport>
<autoUpdateInitializationActionList>
<iniFileGet file="${system_temp_directory}/autoupdater/update.ini" section="Update">
<key>update_download_location</key>
<variable>UpdateDownloadLocation</variable>
</iniFileGet>
<deleteFile>
<path>${UpdateDownloadLocation}/bncert*</path>
</deleteFile>
</autoUpdateInitializationActionList>
<postUpdateDownloadActionList>
<setInstallerVariableFromRegEx name="downloadedFileName" text="${downloadedFilePath}">
<pattern>^(.*)[\:\/]</pattern>
</setInstallerVariableFromRegEx>
<setInstallerVariableFromRegEx name="downloadedFileName" text="${downloadedFileName}">
<pattern>.app.tgz|.app|.exe|.run</pattern>
</setInstallerVariableFromRegEx>
<iniFileGet file="${system_temp_directory}/autoupdater/update.ini" section="Update">
<key>bncert_tool_ui</key>
<variable>toolUI</variable>
</iniFileGet>
<iniFileGet file="${system_temp_directory}/autoupdater/update.ini" section="Update">
<key>bncert_tool_installdir</key>
<variable>toolInstalldir</variable>
</iniFileGet>
<dirName path="${downloadedFilePath}" variable="downloadFolder"/>
<createDirectory path="${toolInstalldir}/bncert"/>
<createSymLink linkName="${toolInstalldir}/bncert-tool" target="${toolInstalldir}/bncert/${downloadedFileName}.${platform_exec_suffix}" abortOnError="0" showMessageOnError="0"/>
<renameFile ruleEvaluationLogic="or" origin="${downloadedFilePath}" destination="${toolInstalldir}/bncert/">
</renameFile>
<if>
<conditionRuleList>
<compareText text="${toolUI}" logic="equals" value="gui"/>
</conditionRuleList>s
<actionList>
<runProgram workingDirectory="${system_temp_directory}" abortOnError="0" showMessageOnError="0">
<program>${toolInstalldir}/bncert/${downloadedFileName}.${platform_exec_suffix}</program>
<programArguments>&</programArguments>
<ruleList>
<platformTest type="linux"></platformTest>
</ruleList>
</runProgram>
</actionList>
<elseActionList>
<exit exitCode="0"/>
</elseActionList>
</if>
</postUpdateDownloadActionList>
</autoUpdateProject>