File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change 23
23
with:
24
24
args: "https://gitlab.com/<namespace>/<repository>"
25
25
env:
26
+ FORCE_PUSH: "true"
26
27
GITLAB_HOSTNAME: "gitlab.com"
27
28
GITLAB_USERNAME: "svboxel"
28
29
GITLAB_PASSWORD: ${{ secrets.GITLAB_PASSWORD }} // Generate here: https://gitlab.com/profile/personal_access_tokens
Original file line number Diff line number Diff line change @@ -31,7 +31,12 @@ sh -c "git config --global core.askPass /cred-helper.sh"
31
31
sh -c " git config --global credential.helper cache"
32
32
sh -c " git remote add mirror $* "
33
33
sh -c " echo pushing to $branch branch at $( git remote get-url --push mirror) "
34
+ if [" $FORCE_PUSH " = " true" ]
35
+ then
36
+ sh -c " git push --force mirror $branch "
37
+ else
34
38
sh -c " git push mirror $branch "
39
+ fi
35
40
36
41
sleep $POLL_TIMEOUT
37
42
You can’t perform that action at this time.
0 commit comments