Add /NoShortcuts parameter for Windows installer

This commit is contained in:
Kenneth Chew 2022-05-20 17:22:30 -04:00
parent cdd83c279c
commit 1ec7878c07
No known key found for this signature in database
GPG Key ID: F17D3E14A07739DA

View File

@ -141,7 +141,7 @@ Section "PolyMC"
SectionEnd SectionEnd
Section "Start Menu Shortcuts" Section "Start Menu Shortcuts" SHORTCUTS
CreateShortcut "$SMPROGRAMS\PolyMC.lnk" "$INSTDIR\polymc.exe" "" "$INSTDIR\polymc.exe" 0 CreateShortcut "$SMPROGRAMS\PolyMC.lnk" "$INSTDIR\polymc.exe" "" "$INSTDIR\polymc.exe" 0
@ -219,3 +219,15 @@ Section "Uninstall"
RMDir "$INSTDIR" RMDir "$INSTDIR"
SectionEnd SectionEnd
;--------------------------------
; Extra command line parameters
Function .onInit
${GetParameters} $R0
${GetOptions} $R0 "/NoShortcuts" $R1
${IfNot} ${Errors}
!insertmacro UnselectSection ${SHORTCUTS}
${EndIf}
FunctionEnd