Files
Mapo-IOB-WIN/gitSpread.bat
T
Samuele Locatelli 464ad6ae84 fix gitspread
2021-08-04 11:25:21 +02:00

30 lines
1.1 KiB
Batchfile

REM Script di replica su altri rami di un branch git
REM l'argomento è il replication level:
REM 0 = solo locale
REM 1 = locale + ramo current remoto
REM 2 = locale + current + develop/master remoto
REM 3 = locale + full remoto
ECHO off
set baseBranch=%1
set pushRemote=%2
git push . %baseBranch%:develop
git push . %baseBranch%:IOB-NET
git push . %baseBranch%:IOB/Euromap63
git push . %baseBranch%:IOB/MTC
git push . %baseBranch%:IobMan
git push . %baseBranch%:master
REM Faccio push remoto condizionale
if %pushRemote% GTR 0 ( git push gitlab.steamware %baseBranch%:%baseBranch% )
if %pushRemote% GTR 1 ( git push gitlab.steamware %baseBranch%:develop )
REM if %pushRemote% GTR 2 ( git push gitlab.steamware %baseBranch%:IOB-NET )
REM if %pushRemote% GTR 2 ( git push gitlab.steamware %baseBranch%:IOB/OPC-UA )
REM if %pushRemote% GTR 2 ( git push gitlab.steamware %baseBranch%:IOB/Euromap63 )
REM if %pushRemote% GTR 2 ( git push gitlab.steamware %baseBranch%:IOB/MTC )
if %pushRemote% GTR 1 ( git push gitlab.steamware %baseBranch%:IobMan )
if %pushRemote% GTR 1 ( git push gitlab.steamware %baseBranch%:master )
ECHO on