Update GitHub workflow to use checkout v4 and configure Git #10
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: PhpUnit Coverage Percentage Badge | ||
| on: | ||
| push: | ||
| branches: | ||
| - main | ||
| jobs: | ||
| build: | ||
| runs-on: ubuntu-latest | ||
| if: "!contains(github.event.head_commit.message, '[ci]')" | ||
| strategy: | ||
| matrix: | ||
| operating-system: [ubuntu-latest] | ||
| php-versions: [ '8.4' ] | ||
| name: P${{ matrix.php-versions }} - L${{ matrix.laravel }} - ${{ matrix.operating-system}} | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| token: ${{ secrets.NUXTIFYTS_BOT_API_KEY }} | ||
|
Check failure on line 22 in .github/workflows/phpunit-coverage-badge.yml
|
||
| - name: Setup Git | ||
| run: | | ||
| git config --global user.name "nuxtifyts-bot" | ||
| git config --global user.email "[email protected]" | ||
| - name: Install PHP versions | ||
| uses: shivammathur/setup-php@v2 | ||
| with: | ||
| php-version: ${{ matrix.php-versions }} | ||
| coverage: xdebug | ||
| extensions: dom, json, libxml, mbstring, xml, xmlwriter, openssl | ||
| - name: Install Dependencies | ||
| run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist | ||
| - name: Show dir | ||
| run: pwd | ||
| - name: PHP Version | ||
| run: php --version | ||
| - name: Run PhpUnit | ||
| run: composer run-script ci-test | ||
| - name: Generate test coverage badge | ||
| uses: timkrase/[email protected] | ||
| with: | ||
| coverage_badge_path: 'badge-coverage.svg' | ||
| push_badge: true | ||
| repo_token: ${{ secrets.GITHUB_TOKEN }} | ||