mirror of
https://github.com/friendica/friendica
synced 2025-04-17 20:30:12 +00:00
merge code quality checks into on workflow
This commit is contained in:
parent
af4cac91b1
commit
432f28ecd1
2 changed files with 35 additions and 47 deletions
|
@ -2,7 +2,7 @@
|
||||||
#
|
#
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
# SPDX-License-Identifier: CC0-1.0
|
||||||
|
|
||||||
name: Code Style
|
name: Code Quality
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
|
@ -11,7 +11,7 @@ on:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
tests:
|
code-style:
|
||||||
name: PHP-CS-Fixer (PHP ${{ matrix.php }})
|
name: PHP-CS-Fixer (PHP ${{ matrix.php }})
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
@ -42,4 +42,36 @@ jobs:
|
||||||
|
|
||||||
- name: Run PHP-CS-Fixer
|
- name: Run PHP-CS-Fixer
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
run: bin/dev/php-cs-fixer/vendor/bin/php-cs-fixer fix --diff --dry-run
|
run: bin/dev/php-cs-fixer/vendor/bin/php-cs-fixer fix --diff --dry-run
|
||||||
|
|
||||||
|
phpstan:
|
||||||
|
name: PHPStan (PHP ${{ matrix.php }})
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
operating-system: ['ubuntu-latest']
|
||||||
|
php: ['8.4']
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
fetch-depth: 2
|
||||||
|
|
||||||
|
- name: Setup PHP with composer and extensions
|
||||||
|
uses: shivammathur/setup-php@v2 #https://github.com/shivammathur/setup-php
|
||||||
|
with:
|
||||||
|
php-version: ${{ matrix.php }}
|
||||||
|
coverage: xdebug
|
||||||
|
tools: none
|
||||||
|
|
||||||
|
- name: Clone addon repository
|
||||||
|
run: git clone -b develop --single-branch https://git.friendi.ca/friendica/friendica-addons.git addon
|
||||||
|
|
||||||
|
- name: Install Composer dependencies
|
||||||
|
uses: "ramsey/composer-install@v2"
|
||||||
|
|
||||||
|
- name: Run PHPStan
|
||||||
|
run: composer run phpstan
|
44
.github/workflows/phpstan.yml
vendored
44
.github/workflows/phpstan.yml
vendored
|
@ -1,44 +0,0 @@
|
||||||
# SPDX-FileCopyrightText: 2010 - 2024 the Friendica project
|
|
||||||
#
|
|
||||||
# SPDX-License-Identifier: CC0-1.0
|
|
||||||
|
|
||||||
name: Static Code Analysis
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
pull_request:
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
|
|
||||||
tests:
|
|
||||||
name: PHPStan (PHP ${{ matrix.php }})
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
|
|
||||||
strategy:
|
|
||||||
fail-fast: false
|
|
||||||
matrix:
|
|
||||||
operating-system: ['ubuntu-latest']
|
|
||||||
php: ['8.4']
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
with:
|
|
||||||
fetch-depth: 2
|
|
||||||
|
|
||||||
- name: Setup PHP with composer and extensions
|
|
||||||
uses: shivammathur/setup-php@v2 #https://github.com/shivammathur/setup-php
|
|
||||||
with:
|
|
||||||
php-version: ${{ matrix.php }}
|
|
||||||
coverage: xdebug
|
|
||||||
tools: none
|
|
||||||
|
|
||||||
- name: Clone addon repository
|
|
||||||
run: git clone -b develop --single-branch https://git.friendi.ca/friendica/friendica-addons.git addon
|
|
||||||
|
|
||||||
- name: Install Composer dependencies
|
|
||||||
uses: "ramsey/composer-install@v2"
|
|
||||||
|
|
||||||
- name: Run PHPStan
|
|
||||||
run: composer run phpstan
|
|
Loading…
Add table
Add a link
Reference in a new issue