change LogDir; add ProductProperty desktoplink, custom-post-install, custom-post-uninstall
fix incorrect path for the InstallDir64
This commit is contained in:
parent
c138d287a8
commit
a390b56419
|
@ -67,6 +67,17 @@ endif
|
|||
comment "Delete program shortcuts"
|
||||
LinkFolder_uninstall
|
||||
|
||||
DefVar $Property_CustomPostUninstall$
|
||||
Set $Property_CustomPostUninstall$ = getProductProperty("custom-post-uninstall","none")
|
||||
if not ($Property_CustomPostUninstall$ = "none")
|
||||
comment "Include custom post uninstall file"
|
||||
if FileExists("%ScriptPath%\custom\" + $Property_CustomPostUninstall$)
|
||||
sub_CustomPostUninstall
|
||||
else
|
||||
LogError "Include script NOT exists (" + $Property_CustomPostUninstall$ +")"
|
||||
endif
|
||||
endif
|
||||
|
||||
[Winbatch_uninstall_msi_old_32]
|
||||
msiexec /x $MsiIdOld32$ /qb! REBOOT=ReallySuppress
|
||||
|
||||
|
@ -106,6 +117,9 @@ del -sf "$InstallDir64$\"
|
|||
; set_subfolder ""
|
||||
; delete_element $ProductId$
|
||||
|
||||
[sub_CustomPostUninstall]
|
||||
include_insert "%ScriptPath%\custom\" + $Property_CustomPostUninstall$
|
||||
|
||||
[Sub_check_exitcode]
|
||||
comment "Test for installation success via exit code"
|
||||
set $ExitCode$ = getLastExitCode
|
||||
|
|
|
@ -23,10 +23,14 @@ DefVar $OLD_VERSION$
|
|||
DefVar $OLD_CREATOR_TAG$
|
||||
DefVar $OLD_RELEASE$
|
||||
|
||||
;Property Variables
|
||||
DefVar $Property_CustomPostInstall$
|
||||
DefVar $Property_DesktopLink$
|
||||
|
||||
Set $INST_SystemType$ = GetSystemType
|
||||
set $INST_architecture$ = GetProductProperty("install_architecture","system specific")
|
||||
|
||||
Set $LogDir$ = "%SystemDrive%\tmp"
|
||||
Set $LogDir$ = "%opsiLogDir%"
|
||||
|
||||
; The token BUILDER_VARIABLES will be replaced by opsi-builder.sh
|
||||
; and adds the following variables:
|
||||
|
@ -47,7 +51,7 @@ Set $LogDir$ = "%SystemDrive%\tmp"
|
|||
Set $MinimumSpace$ = "1 MB"
|
||||
; the path were we find the product after the installation
|
||||
Set $InstallDir32$ = "%ProgramFiles32Dir%\mRemoteNG"
|
||||
Set $InstallDir64$ = "%ProgramFiles64Dir%\mRemoteNG"
|
||||
Set $InstallDir64$ = "%ProgramFiles32Dir%\mRemoteNG"
|
||||
; ----------------------------------------------------------------
|
||||
|
||||
Set $IniCfgFile$ = "%ScriptPath%\opsi-" + $ProductId$ + ".ini"
|
||||
|
@ -77,8 +81,11 @@ else
|
|||
Files_install_32 /32Bit
|
||||
comment "Patch Registry"
|
||||
Registry_install /32Bit
|
||||
comment "Create shortcuts"
|
||||
LinkFolder_install
|
||||
Set $Property_DesktopLink$ = GetProductProperty("DesktopLink","false")
|
||||
if ($Property_DesktopLink$ = "false")
|
||||
comment "Create shortcuts"
|
||||
LinkFolder_install
|
||||
endif
|
||||
endif
|
||||
|
||||
if ($INST_SystemType$ = "64 Bit System") and (($INST_architecture$ = "system specific") or ($INST_architecture$ = "both") or ($INST_architecture$ = "64 only"))
|
||||
|
@ -91,8 +98,21 @@ else
|
|||
Files_install_64 /64Bit
|
||||
comment "Patch Registry"
|
||||
Registry_install /64Bit
|
||||
comment "Create shortcuts"
|
||||
LinkFolder_install
|
||||
Set $Property_DesktopLink$ = GetProductProperty("DesktopLink","false")
|
||||
if ($Property_DesktopLink$ = "false")
|
||||
comment "Create shortcuts"
|
||||
LinkFolder_install
|
||||
endif
|
||||
endif
|
||||
|
||||
Set $Property_CustomPostInstall$ = getProductProperty("custom-post-install","none")
|
||||
if not ($Property_CustomPostInstall$ = "none")
|
||||
comment "Include custom post install file"
|
||||
if FileExists("%ScriptPath%\custom\" + $Property_CustomPostInstall$)
|
||||
sub_CustomPostInstall
|
||||
else
|
||||
LogError "Include script NOT exists (" + $Property_CustomPostInstall$ +")"
|
||||
endif
|
||||
endif
|
||||
|
||||
endif
|
||||
|
@ -128,6 +148,9 @@ copy "$IniCfgFile$" "$InstallDir64$"
|
|||
; set "name3" = REG_BINARY:00 af 99 cd
|
||||
|
||||
[LinkFolder_install]
|
||||
set_basefolder common_desktopdirectory
|
||||
set_subfolder ""
|
||||
delete_element mRemoteNG
|
||||
; Example of deleting a folder from AllUsers startmenu:
|
||||
;
|
||||
; set_basefolder common_programs
|
||||
|
@ -161,6 +184,9 @@ copy "$IniCfgFile$" "$InstallDir64$"
|
|||
; icon_index: 2
|
||||
; end_link
|
||||
|
||||
[sub_CustomPostInstall]
|
||||
include_insert "%ScriptPath%\custom\" + $Property_CustomPostInstall$
|
||||
|
||||
[Sub_check_exitcode]
|
||||
comment "Test for installation success via exit code"
|
||||
set $ExitCode$ = getLastExitCode
|
||||
|
|
|
@ -25,7 +25,7 @@ DefVar $OLD_RELEASE$
|
|||
Set $INST_SystemType$ = GetSystemType
|
||||
set $INST_architecture$ = GetProductProperty("install_architecture","system specific")
|
||||
|
||||
Set $LogDir$ = "%SystemDrive%\tmp"
|
||||
Set $LogDir$ = "%opsiLogDir%"
|
||||
|
||||
; The token BUILDER_VARIABLES will be replaced by opsi-builder.sh
|
||||
; and adds the following variables:
|
||||
|
@ -41,7 +41,7 @@ Set $LogDir$ = "%SystemDrive%\tmp"
|
|||
; - Please edit the following values -
|
||||
; ----------------------------------------------------------------
|
||||
Set $InstallDir32$ = "%ProgramFiles32Dir%\mRemoteNG"
|
||||
Set $InstallDir64$ = "%ProgramFiles64Dir%\mRemoteNG"
|
||||
Set $InstallDir64$ = "%ProgramFiles32Dir%\mRemoteNG"
|
||||
; ----------------------------------------------------------------
|
||||
|
||||
Set $IniCfgFile$ = "%ScriptPath%\opsi-" + $ProductId$ + ".ini"
|
||||
|
|
22
OPSI/control
22
OPSI/control
|
@ -27,4 +27,26 @@ requiredProduct: sereby.aio
|
|||
requiredStatus: installed
|
||||
requirementType: before
|
||||
|
||||
[ProductProperty]
|
||||
type: bool
|
||||
name: desktoplink
|
||||
description: Show Desktop Link on/off
|
||||
default: False
|
||||
|
||||
[ProductProperty]
|
||||
type: unicode
|
||||
name: custom-post-install
|
||||
multivalue: False
|
||||
editable: True
|
||||
description: Define filename for include script in custom directory after installation
|
||||
values: ["none"]
|
||||
default: ["none"]
|
||||
|
||||
[ProductProperty]
|
||||
type: unicode
|
||||
name: custom-post-uninstall
|
||||
multivalue: False
|
||||
editable: True
|
||||
description: Define filename for include script in custom directory after uninstallation
|
||||
values: ["none"]
|
||||
default: ["none"]
|
||||
|
|
Loading…
Reference in New Issue