Skip to content

Commit

Permalink
feat(nsis): boring installer — respect /allusers
Browse files Browse the repository at this point in the history
Closes #845
  • Loading branch information
develar committed Nov 2, 2016
1 parent 4ac12bf commit 4536e91
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions templates/nsis/boringInstaller.nsh
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,19 @@
StrCpy $hasPerUserInstallation "1"
${endif}

${GetParameters} $R0
${GetOptions} $R0 "/allusers" $R1
${IfNot} ${Errors}
!insertmacro setInstallModePerAllUsers
Goto FEnd
${EndIf}

${GetOptions} $R0 "/currentuser" $R1
${IfNot} ${Errors}
!insertmacro setInstallModePerUser
Goto FEnd
${EndIf}

${if} $hasPerUserInstallation == "1"
${andif} $hasPerMachineInstallation == "0"
!insertmacro setInstallModePerUser
Expand All @@ -88,6 +101,8 @@
!insertmacro setInstallModePerUser
!endif
${endif}

FEnd:
!endif
!macroend

Expand Down

0 comments on commit 4536e91

Please sign in to comment.