Skip to content

Commit 8fee0d8

Browse files
committed
Turned off some MessageBox for the silent mode
1 parent eb5e72e commit 8fee0d8

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

nsis/postgresql.nsi

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -342,6 +342,7 @@ SectionEnd
342342

343343
Section $(componentServer) sec1
344344

345+
345346
${if} $PG_OLD_DIR != "" ; exist PG install
346347
${if} $isStopped == 0
347348
MessageBox MB_YESNO|MB_ICONQUESTION "$(MESS_STOP_SERVER)" IDYES doitStop IDNO noyetStop
@@ -583,8 +584,10 @@ Section $(componentServer) sec1
583584
FileClose $LogFile ;Closes the filled file
584585

585586
${if} $0 != 1
587+
IfSilent +2
586588
MessageBox MB_OK|MB_ICONINFORMATION $(MESS_ERROR_INITDB2)
587589
${else}
590+
IfSilent +2
588591
MessageBox MB_OK|MB_ICONINFORMATION $(MESS_ERROR_INITDB)
589592
${endif}
590593

@@ -782,14 +785,15 @@ Section $(componentServer) sec1
782785
call checkServiceIsRunning
783786
pop $0
784787
${if} $0 == ""
785-
Sleep 5000
788+
Sleep 7000
786789
call checkServiceIsRunning
787790
pop $0
788791
${if} $0 == ""
789792
DetailPrint "Error: service is not running!"
790-
MessageBox MB_OK|MB_ICONSTOP "$(MESS_ERROR_SERVER)"
791793
FileWrite $LogFile "Error: service $ServiceID_text is not running!$\r$\n"
792794
FileClose $LogFile
795+
IfSilent +2
796+
MessageBox MB_OK|MB_ICONSTOP "$(MESS_ERROR_SERVER)"
793797
Abort
794798
${endif}
795799
${endif}
@@ -819,10 +823,11 @@ Section $(componentServer) sec1
819823
DetailPrint "Output: $1"
820824
FileWrite $LogFile "Checking connection has return $0 $\r$\n"
821825
FileWrite $LogFile "Output: $1 $\r$\n"
826+
FileClose $LogFile
822827

823828
;MessageBox MB_OK "Create adminpack error: $1"
824-
MessageBox MB_OK|MB_ICONSTOP "$(MESS_ERROR_SERVER)"
825-
FileClose $LogFile
829+
IfSilent +2
830+
MessageBox MB_OK|MB_ICONSTOP "$(MESS_ERROR_SERVER)"
826831
Abort
827832
${else}
828833
DetailPrint "Checking connection is OK"
@@ -857,6 +862,7 @@ Section $(componentServer) sec1
857862
FileWrite $LogFile "Output: $1 $\r$\n"
858863

859864
;MessageBox MB_OK "Create adminpack error: $1"
865+
IfSilent +2
860866
MessageBox MB_OK|MB_ICONSTOP "$(MESS_ERROR_SERVER)"
861867
${else}
862868
DetailPrint "Create adminpack OK"

0 commit comments

Comments
 (0)