diff --git a/.github/workflows/coding-standards.yml b/.github/workflows/coding-standards.yml index b2ace0d..5bd6124 100644 --- a/.github/workflows/coding-standards.yml +++ b/.github/workflows/coding-standards.yml @@ -12,18 +12,20 @@ on: - '**' workflow_dispatch: +permissions: {} + jobs: test: name: ${{ matrix.label }} + permissions: + contents: read uses: johnbillion/plugin-infrastructure/.github/workflows/reusable-coding-standards.yml@trunk strategy: matrix: label: - PHP php: - # Newest and oldest supported versions of PHP - '8.4' - - '7.4' fail-fast: false with: php: ${{ matrix.php }} diff --git a/.github/workflows/nightly-tests.yml b/.github/workflows/nightly-tests.yml index c44cd64..982a3b9 100644 --- a/.github/workflows/nightly-tests.yml +++ b/.github/workflows/nightly-tests.yml @@ -21,23 +21,46 @@ on: - '.github/workflows/nightly-tests.yml' workflow_dispatch: +permissions: {} + jobs: standards: name: Nightly ${{ matrix.label }} + permissions: + contents: read strategy: matrix: label: - 'standards' + php: + # Newest supported version of PHP + - '8.4' + fail-fast: false + uses: johnbillion/plugin-infrastructure/.github/workflows/reusable-coding-standards.yml@trunk + with: + php: ${{ matrix.php }} + + static-analysis: + name: Nightly ${{ matrix.label }} + permissions: + contents: read + strategy: + matrix: + label: + - 'static analysis' php: # Newest and oldest supported versions of PHP - '8.4' - '7.4' fail-fast: false - uses: johnbillion/plugin-infrastructure/.github/workflows/reusable-coding-standards.yml@trunk + uses: johnbillion/plugin-infrastructure/.github/workflows/reusable-static-analysis.yml@trunk with: php: ${{ matrix.php }} + integration: name: Nightly ${{ matrix.label }} + permissions: + contents: read uses: johnbillion/plugin-infrastructure/.github/workflows/reusable-integration-tests.yml@trunk strategy: matrix: diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml new file mode 100644 index 0000000..7ca9bb9 --- /dev/null +++ b/.github/workflows/static-analysis.yml @@ -0,0 +1,42 @@ +# yaml-language-server: $schema=https://json.schemastore.org/github-workflow + +name: Static Analysis +on: + push: + branches: + - 'develop' + - 'trunk' + paths: + - '.github/workflows/static-analysis.yml' + - '**.php' + - 'composer.json' + - 'phpstan.neon.dist' + pull_request: + branches: + - '**' + paths: + - '.github/workflows/static-analysis.yml' + - '**.php' + - 'composer.json' + - 'phpstan.neon.dist' + workflow_dispatch: + +permissions: {} + +jobs: + test: + name: ${{ matrix.label }} + permissions: + contents: read + uses: johnbillion/plugin-infrastructure/.github/workflows/reusable-static-analysis.yml@trunk + strategy: + matrix: + label: + - 'PHP' + php: + # Newest and oldest supported versions of PHP + - '8.4' + - '7.4' + fail-fast: false + with: + php: ${{ matrix.php }}