Skip to content

Commit

Permalink
appveyor-retry.cmd: minor cosmetic tweaks (#2686)
Browse files Browse the repository at this point in the history
* lowercase commands for consistency
* remove `:` from labels since it's not needed
  • Loading branch information
XhmikosR authored and FeodorFitsner committed Oct 9, 2018
1 parent 8f4c240 commit 457de26
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions scripts/appveyor-retry.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@ set maxRetries=3
:RUN
%*
set LastErrorLevel=%ERRORLEVEL%
IF %LastErrorLevel% == 0 GOTO :EOF
if %LastErrorLevel% == 0 goto :EOF
set /a retryNumber=%retryNumber%+1
IF %reTryNumber% == %maxRetries% (GOTO :FAILED)
if %reTryNumber% == %maxRetries% (goto FAILED)

:RETRY
set /a retryNumberDisp=%retryNumber%+1
@echo Command "%*" failed with exit code %LastErrorLevel%. Retrying %retryNumberDisp% of %maxRetries%
GOTO :RUN
goto RUN

: FAILED
@echo Sorry, we tried running command for %maxRetries% times and all attempts were unsuccessful!
EXIT /B %LastErrorLevel%
:FAILED
@echo Sorry, we tried running the command for %maxRetries% times and all attempts were unsuccessful!
exit /B %LastErrorLevel%

0 comments on commit 457de26

Please sign in to comment.