From c07030cfc2083424bfa6d084f2b0c0f67fcf1bc5 Mon Sep 17 00:00:00 2001 From: tligui_y Date: Mon, 7 Jul 2025 16:37:15 +0200 Subject: [PATCH] Update .gitea/workflows/test.yml --- .gitea/workflows/test.yml | 28 ++++++++++++++++++++-------- 1 file changed, 20 insertions(+), 8 deletions(-) diff --git a/.gitea/workflows/test.yml b/.gitea/workflows/test.yml index 9874d1b9..79db829c 100644 --- a/.gitea/workflows/test.yml +++ b/.gitea/workflows/test.yml @@ -63,15 +63,27 @@ jobs: env: CI_TOKEN: ${{ secrets.CI_TOKEN }} - - name: Serve Allure Report on runner + - name: Deploy Allure report to allure-report branch run: | - nohup python3 -m http.server 8080 --directory ci-reports/allure > http.log 2>&1 & - sleep 3 - echo "--------------------------------------------------" - echo "Allure report available at the address :" - ip=$(ip route get 1 | awk '{for(i=1;i<=NF;i++) if ($i=="src") print $(i+1)}') - echo "➡️ http://$ip:8080/index.html" - echo "--------------------------------------------------" + git config user.name "ci-bot" + git config user.email "ci-bot@example.com" + + # Copie les fichiers dans un dossier temporaire + cp -r ci-reports/allure /tmp/allure-report + + # Crée une branche orpheline propre + git fetch origin + git checkout --orphan allure-report + git rm -rf . || true + + # Copie les fichiers HTML + cp -r /tmp/allure-report/* . + git add . + git commit -m "Deploy Allure report" + git push --force https://ci-token:${{ secrets.CI_TOKEN }}@gitea.psi.ch/tligui_y/slic.git HEAD:allure-report + env: + CI_TOKEN: ${{ secrets.CI_TOKEN }} + - name: Cleanup Pixi cache run: |