mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-23 05:25:50 +03:00
NSIS: accept /noautoupdate
This commit is contained in:
parent
958253bb2b
commit
4db7b5f2a7
1 changed files with 12 additions and 0 deletions
|
@ -54,6 +54,7 @@
|
||||||
!define VERSION "@CPACK_PACKAGE_VERSION@"
|
!define VERSION "@CPACK_PACKAGE_VERSION@"
|
||||||
|
|
||||||
Var InstallRunIfSilent
|
Var InstallRunIfSilent
|
||||||
|
Var NoAutomaticUpdates
|
||||||
|
|
||||||
;-----------------------------------------------------------------------------
|
;-----------------------------------------------------------------------------
|
||||||
; Installer build timestamp.
|
; Installer build timestamp.
|
||||||
|
@ -628,6 +629,13 @@ Function .onInit
|
||||||
StrCpy $InstallRunIfSilent "yes"
|
StrCpy $InstallRunIfSilent "yes"
|
||||||
${EndIf}
|
${EndIf}
|
||||||
|
|
||||||
|
${GetParameters} $R0
|
||||||
|
${GetOptions} $R0 "/noautoupdate" $R0
|
||||||
|
${IfNot} ${Errors}
|
||||||
|
StrCpy $NoAutomaticUpdates "yes"
|
||||||
|
${EndIf}
|
||||||
|
|
||||||
|
|
||||||
!insertmacro INSTALLOPTIONS_EXTRACT "NSIS.InstallOptions.ini"
|
!insertmacro INSTALLOPTIONS_EXTRACT "NSIS.InstallOptions.ini"
|
||||||
|
|
||||||
; uncomment this line if you want to see the language selection
|
; uncomment this line if you want to see the language selection
|
||||||
|
@ -695,6 +703,10 @@ FunctionEnd
|
||||||
Function .onInstSuccess
|
Function .onInstSuccess
|
||||||
${MementoSectionSave}
|
${MementoSectionSave}
|
||||||
|
|
||||||
|
${If} $NoAutomaticUpdates == "yes"
|
||||||
|
WriteRegDWORD HKLM "Software\${APPLICATION_VENDOR}\${APPLICATION_NAME}" "skipUpdateCheck" "1"
|
||||||
|
${EndIf}
|
||||||
|
|
||||||
${If} ${Silent}
|
${If} ${Silent}
|
||||||
${AndIf} $InstallRunIfSilent == "yes"
|
${AndIf} $InstallRunIfSilent == "yes"
|
||||||
Call LaunchApplication
|
Call LaunchApplication
|
||||||
|
|
Loading…
Reference in a new issue