File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11name : PaddleFormers Code Clone
22description : " PaddleFormers clone and upload"
3-
43on :
54 workflow_call :
65 inputs :
7- bos_dir :
8- type : string
9- required : false
10- default : ' PaddleFormers'
6+ bos_dir :
7+ type : string
8+ required : false
9+ default : ' PaddleFormers'
1110 outputs :
1211 repo_archive_url :
1312 description : " Compressed source code archive."
2221 - name : Clone PaddleFormers
2322 uses : actions/checkout@v4
2423 with :
25- ref : ${{ github.event_name == 'pull_request'
26- && github.event.pull_request.base.ref
27- || github.ref_name }}
24+ ref : ${{ github.event_name == 'pull_request' && github.event.pull_request.base.ref || github.ref_name }}
2825 submodules : ' recursive'
2926 fetch-depth : 1000
30-
3127 - name : Merge PR (if needed)
3228 if : ${{ github.event_name == 'pull_request' }}
3329 run : |
3834 git merge --no-ff pr/${{ github.event.pull_request.number }}
3935 echo "PR Branch log "
4036 git log --oneline -n 5 pr/${{ github.event.pull_request.number }}
37+ - name : Init submodules
38+ run : |
39+ git submodule sync --recursive
40+ git submodule update --init --recursive
4141 - uses : actions/setup-python@v5
4242 with :
4343 python-version : ' 3.10'
4747 AK : paddle
4848 SK : paddle
4949 run : |
50- git config --unset http.https://github.com/.extraheader
51- git submodule foreach --recursive sh -c "git config --local --unset-all 'http.https://github.com/.extraheader'"
52- git submodule foreach --recursive sh -c "git config remote.origin.fetch '+refs/heads/*:refs/remotes/origin/*'"
50+ git config --unset-all http.https://github.com/.extraheader || true
51+ git submodule foreach --recursive sh -c "git config --local --unset-all 'http.https://github.com/.extraheader' || true "
52+ git submodule foreach --recursive sh -c "git config remote.origin.fetch '+refs/heads/*:refs/remotes/origin/*' || true "
5353 echo "Current HEAD Log:"
5454 git log --oneline -n 5
5555 ls
You can’t perform that action at this time.
0 commit comments