From ba095ed637894aab24f043ba5eeae06204e5e960 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Thu, 28 Apr 2022 14:00:29 +0200 Subject: [PATCH] Upload report to GitHub Pages --- .github/workflows/test-coverage.yml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/.github/workflows/test-coverage.yml b/.github/workflows/test-coverage.yml index 95943a6..e46408e 100644 --- a/.github/workflows/test-coverage.yml +++ b/.github/workflows/test-coverage.yml @@ -98,6 +98,32 @@ jobs: name: 'coverage-report' path: 'covrep' + upload-coverage-report: + needs: create-coverage-report + runs-on: ubuntu-latest + + steps: + - name: Download coverage report artifact + uses: actions/download-artifact@v3 + with: + name: coverage-report + path: coverage-report + + - name: Write run metadata to file + run: | + currentDate=`date` + echo "Report automatically uploaded by GitHub at $currentDate" > coverage-report/report-information.txt + + - name: Upload report to GitHub Pages + uses: cpina/github-action-push-to-another-repository@v1.4.2 + + env: + API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} + with: + source-directory: "." + destination-github-username: "hydephp" + destination-repository-name: "developer-tools" + target-branch: gh-pages #create-php-docs: # runs-on: ubuntu-latest