oai-pmh2/.github/workflows/phpmd.yml

45 lines
942 B
YAML
Raw Permalink Normal View History

2024-01-03 16:54:13 +01:00
name: PHP Mess Detector
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
permissions:
contents: read
jobs:
PHPMD:
name: PHPMD Scanner
runs-on: ubuntu-latest
permissions:
contents: read
security-events: write
actions: read
steps:
- name: Checkout Source Code
uses: actions/checkout@v4
- name: Setup Environment
2024-08-09 12:29:36 +02:00
uses: php-actions/composer@v6
2024-01-03 16:54:13 +01:00
with:
2024-08-09 12:29:36 +02:00
command: install
php_version: "8.1"
2024-01-03 16:54:13 +01:00
2024-08-09 12:29:36 +02:00
- name: Run PHP Mess Detector
uses: php-actions/phpmd@v1
with:
2024-10-23 11:43:32 +02:00
path: bin/,public/,src/
2024-08-09 12:29:36 +02:00
php_version: "8.1"
ruleset: .phpmd.dist.xml
output: sarif
reportfile: phpmd-results.sarif
2024-01-03 16:54:13 +01:00
- name: Upload Analysis Results
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: phpmd-results.sarif
wait-for-processing: true