File tree Expand file tree Collapse file tree 1 file changed +30
-0
lines changed Expand file tree Collapse file tree 1 file changed +30
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Sync-To-CNBC
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - master
7
+
8
+ jobs :
9
+ push-to-mirror :
10
+ runs-on : ubuntu-latest
11
+ steps :
12
+ - name : Clone
13
+ run : |
14
+ git init
15
+ git remote add origin https://github.com/${GITHUB_REPOSITORY}.git
16
+ git fetch --all
17
+ for branch in `git branch -a | grep remotes | grep -v HEAD`; do
18
+ git branch --track ${branch##*/} $branch
19
+ done
20
+ - name : Push to CNBC
21
+ run : |
22
+ remote_repo="https://${CNBC_USERNAME}:${CNBC_PASSWORD}@cnb.cool/tca/tools/${GITHUB_REPOSITORY##*/}.git"
23
+ git remote add cnbc "${remote_repo}"
24
+ git show-ref # debug
25
+ git branch --verbose
26
+ git push --all cnbc
27
+ git push --tags cnbc
28
+ env :
29
+ CNBC_USERNAME : ${{ secrets.CNBC_USERNAME }}
30
+ CNBC_PASSWORD : ${{ secrets.CNBC_PASSWORD }}
You can’t perform that action at this time.
0 commit comments