- 新增 _get_gitea_config.py 从 YAML 读取 URL/repo/token
- _common.sh 改为通过 eval python 脚本加载配置
- GITEA_CICD_SETUP.md / DEV_AGENT.md / QE_AGENT.md 更新文档
- CI 工作流改用 ${{ gitea.server_url }} / ${{ gitea.repository }}
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -23,7 +23,7 @@ jobs:
|
||||
steps:
|
||||
- name: Checkout main branch
|
||||
run: |
|
||||
git clone --depth 1 https://git.zywl.me/pzhang_zywl/document_analyzer.git .
|
||||
git clone --depth 1 ${{ gitea.server_url }}/${{ gitea.repository }}.git .
|
||||
git checkout main
|
||||
|
||||
- name: Install dependencies
|
||||
@@ -57,6 +57,8 @@ jobs:
|
||||
python scripts/create_failure_issue.py \
|
||||
--sha "${{ github.sha }}" --branch "main" \
|
||||
--run "${{ github.run_number }}" \
|
||||
--gitea-url "${{ gitea.server_url }}" \
|
||||
--repo "${{ gitea.repository }}" \
|
||||
--message "QE Acceptance: ${SUMMARY:-pipeline failed}" \
|
||||
--workflow "QE Acceptance" \
|
||||
--labels "acceptance-failure,agent-task"
|
||||
|
||||
@@ -18,10 +18,7 @@ jobs:
|
||||
RUN_URL="${{ github.event.workflow_run.html_url }}"
|
||||
COMMIT_MSG="${{ github.event.workflow_run.head_commit.message }}"
|
||||
|
||||
curl -s -X POST "${{ env.GITEA_URL }}/api/v1/repos/${{ env.GITEA_REPO }}/issues" \
|
||||
curl -s -X POST "${{ gitea.server_url }}/api/v1/repos/${{ gitea.repository }}/issues" \
|
||||
-H "Authorization: token ${{ secrets.GITEA_TOKEN }}" \
|
||||
-H "Content-Type: application/json" \
|
||||
-d "{\"title\":\"CI Failure: ${COMMIT_MSG}\",\"body\":\"## CI 测试失败\n\n- **Commit:** ${SHA_SHORT}\n- **Branch:** ${BRANCH}\n- **工作流:** ${RUN_URL}\n\n请检查上述链接查看失败详情。\n\n### 下一步\n- [ ] 分析失败原因\n- [ ] 修复代码\n- [ ] 提交 PR 触发 CI 重测\",\"labels\":[\"ci-failure\",\"agent-task\"]}"
|
||||
env:
|
||||
GITEA_URL: https://git.zywl.me
|
||||
GITEA_REPO: pzhang_zywl/document_analyzer
|
||||
|
||||
@@ -12,7 +12,7 @@ jobs:
|
||||
steps:
|
||||
- name: Checkout code from Gitea
|
||||
run: |
|
||||
git clone --depth 1 https://git.zywl.me/pzhang_zywl/document_analyzer.git .
|
||||
git clone --depth 1 ${{ gitea.server_url }}/${{ gitea.repository }}.git .
|
||||
git fetch origin ${{ github.sha }}
|
||||
git checkout ${{ github.sha }}
|
||||
|
||||
@@ -31,4 +31,6 @@ jobs:
|
||||
--sha "${{ github.sha }}"
|
||||
--branch "${{ github.ref_name }}"
|
||||
--run "${{ github.run_number }}"
|
||||
--gitea-url "${{ gitea.server_url }}"
|
||||
--repo "${{ gitea.repository }}"
|
||||
--message "${{ github.event.head_commit.message }}"
|
||||
|
||||
Reference in New Issue
Block a user