forked from Wavyzz/dolibarr
Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 5. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v4...v5) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '5' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
44 lines
1.2 KiB
YAML
44 lines
1.2 KiB
YAML
---
|
|
on:
|
|
# workflow called by the parent workflow ci.yml
|
|
workflow_call:
|
|
inputs:
|
|
gh_event:
|
|
required: true
|
|
type: string
|
|
# can run job manually
|
|
workflow_dispatch:
|
|
|
|
concurrency:
|
|
group: phan-${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
env:
|
|
gh_event: ${{ inputs.gh_event || github.event_name }}
|
|
PHAN_CONFIG: dev/tools/phan/config.php
|
|
PHAN_BASELINE: dev/tools/phan/baseline.txt
|
|
PHAN_MIN_PHP: 7.0
|
|
PHAN_QUICK: ${{ github.event.schedule && '' || '--quick' }}
|
|
GITHUB_JSON: ${{ toJSON(github) }} # Helps in debugging Github Action
|
|
|
|
name: phan
|
|
jobs:
|
|
phan:
|
|
name: Run phan
|
|
runs-on: ubuntu-latest
|
|
# Do not run schedule on forks
|
|
if: |
|
|
github.repository == 'Dolibarr/dolibarr'
|
|
|| github.event.schedule == false
|
|
steps:
|
|
- uses: actions/checkout@v5
|
|
- name: Setup PHP
|
|
uses: shivammathur/setup-php@v2
|
|
with:
|
|
php-version: 8.2
|
|
coverage: none # disable xdebug, pcov
|
|
tools: phan
|
|
- name: Run Phan analysis
|
|
run: |
|
|
# shellcheck disable=2086
|
|
phan $PHAN_QUICK -k "$PHAN_CONFIG" -B "$PHAN_BASELINE" --analyze-twice --minimum-target-php-version "$PHAN_MIN_PHP" --output-mode=github
|