Skip to content

GH Actions: Bump ramsey/composer-install from 2 to 3 #39

GH Actions: Bump ramsey/composer-install from 2 to 3

GH Actions: Bump ramsey/composer-install from 2 to 3 #39

Workflow file for this run

name: "Integrate"
on:
push:
paths-ignore:
- '**.md'
pull_request:
paths-ignore:
- '**.md'
# Prevent multiple unnecessary CI runs on the same branch.
# Link: https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions#concurrency
concurrency:
group: "${{ github.workflow }}-${{ github.ref }}"
cancel-in-progress: true
jobs:
syntax_errors:
name: "1️⃣ Syntax errors checks"
runs-on: "ubuntu-latest"
steps:
- name: "Set up PHP"
uses: "shivammathur/setup-php@v2"
with:
php-version: "7.4"
coverage: "none"
- name: "Checkout code"
uses: "actions/checkout@v3"
- name: "Find non-printable ASCII characters"
run: |
! LC_ALL=C.UTF-8 find . -type f -name "*.php" -print0 | xargs -0 -- grep -PHn "[^\t -~]"
- name: "Install dependencies"
uses: "ramsey/composer-install@v3"
with:
dependency-versions: "highest"
- name: "Check source code for syntax errors"
run: "composer exec -- parallel-lint src/"
static_analysis:
name: "2️⃣ Static analysis checks"
needs:
- "syntax_errors"
runs-on: "ubuntu-latest"
steps:
- name: "Set up PHP"
uses: "shivammathur/setup-php@v2"
with:
php-version: "7.4"
coverage: "none"
- name: "Checkout code"
uses: "actions/checkout@v3"
- name: "Validate Composer configuration"
run: "composer validate --strict"
- name: "Install dependencies"
uses: "ramsey/composer-install@v3"
with:
dependency-versions: "highest"
- name: "Execute static analysis"
run: "composer run analyze"
coding_standards:
name: "3️⃣ Coding standards checks"
needs:
- "syntax_errors"
runs-on: "ubuntu-latest"
steps:
- name: "Set up PHP"
uses: "shivammathur/setup-php@v2"
with:
php-version: "7.4"
coverage: "none"
tools: "cs2pr"
- name: "Checkout code"
uses: "actions/checkout@v3"
- name: "Check adherence to EditorConfig"
uses: "greut/eclint-action@v0"
with:
eclint_args: ""
- name: "Install dependencies"
uses: "ramsey/composer-install@v3"
with:
dependency-versions: "highest"
- name: "Check coding style"
run: "composer run standards:check"