Skip to content
Merged
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
36 changes: 8 additions & 28 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,43 +1,23 @@
# Name of workflow
name: PHP CI

# Trigger the workflow on push or pull request
on:
- push
- pull_request

jobs:
build:

# The type of machine to run the job on
runs-on: ubuntu-latest
strategy:
matrix:
php-versions: ['8.1', '8.2', '8.3']

steps:
# Check-out repository under GitHub workspace
# https://github.com/actions/checkout
- uses: actions/checkout@v2
# Step's name
- name: Setup PHP
# Action gives to setup the PHP environment to test application
# https://github.com/shivammathur/setup-php
uses: shivammathur/setup-php@v2
with:
# Specify the PHP version
php-version: '7.4'
- name: Install
# Install project
run: make install
- name: Run linter
# Run Linter
run: make lint
# Publish code coverage on Code Climate
# https://github.com/paambaati/codeclimate-action
- name: Run test & publish code coverage
uses: paambaati/[email protected]
# Add Code Climate secret key
env:
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }}
with:
coverageCommand: make test-coverage
coverageLocations: ${{github.workplace}}/build/logs/clover.xml:clover
debug: true
php-version: ${{ matrix.php-versions }}

- run: make install
- run: make lint
- run: make test