Skip to content

Commit 3ee3fc5

Browse files
rootrisemeup1
authored andcommitted
fix ci build ops whl bug
1 parent 87bb9ef commit 3ee3fc5

1 file changed

Lines changed: 12 additions & 12 deletions

File tree

.github/workflows/_clone_linux.yml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
name: PaddleFormers Code Clone
22
description: "PaddleFormers clone and upload"
3-
43
on:
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."
@@ -22,12 +21,9 @@ jobs:
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: |
@@ -38,6 +34,10 @@ jobs:
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'
@@ -47,9 +47,9 @@ jobs:
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

0 commit comments

Comments
 (0)