Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 28 additions & 5 deletions .github/workflows/lava-trigger.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,33 @@ jobs:
runs-on: 'ubuntu-latest'

steps:
- uses: actions/checkout@v6
with:
repository: ${{ inputs.testcase_repo }}
ref: ${{ inputs.testcase_ref || 'main' }}
- name: checkout scm
shell: bash
run: |
testcase_repo="${{ inputs.testcase_repo }}"
fetch_ref=${{ inputs.testcase_ref || 'main' }}

if [ "${testcase_repo:0:4}" != 'http' ] or [ "${testcase_repo:0:4}" != 'git@' ]; then
testcase_repo="https://github.com/${testcase_repo}.git"
fi

git init .

set -ex
git config user.email rvci@isrc.iscas.ac.cn
git config user.name rvci
git remote add origin "${testcase_repo}"
res=false
for((retry_times=0; retry_times < 10; retry_times++)); do
if git fetch origin "$fetch_ref":"$fetch_ref" --progress; then
res=true
break
fi
sleep 5
done
[ "$res" = "true" ] && echo "fetch repo success."

git checkout "$fetch_ref"

- name: install depends
run: |
Expand Down Expand Up @@ -224,7 +247,7 @@ jobs:
.replace("${job_name}", job_name)\
.replace("${kernel_image_url}", kernel_download_url)\
.replace("${rootfs_image_url}", rootfs_download_url)\
.replace("${testcase_repo}", f"https://github.com/{testcase_repo}.git")\
.replace("${testcase_repo}", testcase_repo if testcase_repo.startswith('http', 'git@') else f"https://github.com/{testcase_repo}.git")\
.replace("${testitem_name}", testitem_name)\
.replace("${testcase_path}", testcase_path)\
.replace("${ltp_testsuite}", ltp_testsuite)\
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/parse-rvck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ jobs:
echo "ISSUE_ID=$(cat ISSUE_ID)" >> $GITHUB_OUTPUT
echo "COMMIT_URL=$(cat COMMIT_URL)" >> $GITHUB_OUTPUT
echo "NEED_RUN_JOB=$(cat job || echo 'kunit-test,kernel-build,check-patch,lava-trigger')" >> $GITHUB_OUTPUT
echo "testcase_repo=$(cat testcase_repo || echo 'RVCK-Project/lavaci')" >> $GITHUB_OUTPUT
echo "testcase_repo=$(cat testcase_repo || echo 'https://git.openruyi.cn/wangliu-iscas/lavaci-mirror.git')" >> $GITHUB_OUTPUT
echo "lava_hardware=$(cat lava_hardware || echo '')" >> $GITHUB_OUTPUT
for f in lava_template_*; do
[ ! -f "$f" ] && continue
Expand Down