Last active
October 15, 2021 17:20
-
-
Save GlinZachariah/cd25e9590b55513f6f4591583df44171 to your computer and use it in GitHub Desktop.
Update Maven projects automatically
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@ECHO OFF | |
ECHO RUNNING AUTOUPDATER.. | |
TIMEOUT 2 >NUL | |
::saving the current working directory | |
set cwd=%cd% | |
::specify a build.txt file with path of each dependencies and projects to be built in order | |
for /f "tokens=*" %%s in (build.txt) do( | |
cd %%s | |
call :auto_update %%s | |
cd %cwd% | |
) | |
:: Check the logs for any errors before application termination | |
pause | |
GOTO :eof | |
:auto_update | |
ECHO FETCHING FOR %1 | |
START /wait "Running install.." CMD /c git switch master && git pull && mvn clean install -DskipTests | |
ECHO COMPLETED MVN INSTALLATION | |
EXIT /B |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment