Skip to content

Commit

Permalink
PhpCsFixer: Execute on pull requests (#860)
Browse files Browse the repository at this point in the history
  • Loading branch information
blankse authored Jun 12, 2024
1 parent 053f11f commit 1c2aed1
Showing 1 changed file with 13 additions and 5 deletions.
18 changes: 13 additions & 5 deletions .github/workflows/php-cs-fixer.yaml
Original file line number Diff line number Diff line change
@@ -1,27 +1,35 @@
name: "PHP-CS-Fixer"

on:
pull_request_target:
branches:
- "[0-9]+.[0-9]+"
- "[0-9]+.x"
- "feature-*"
push:
branches:
- "[0-9]+.[0-9]+"
- "[0-9]+.x"
- "*_actions"
- "feature-*"

permissions:
contents: read
contents: read

jobs:
php-cs-fixer:
permissions:
contents: write # for stefanzweifel/git-auto-commit-action to push code in repo
contents: write # for stefanzweifel/git-auto-commit-action to push code in repo
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}
ref: ${{ github.event.pull_request.head.ref }}
repository: ${{ github.event.pull_request.head.repo.full_name }}

- name: PHP-CS-Fixer
uses: docker://oskarstark/php-cs-fixer-ga:latest

- uses: stefanzweifel/git-auto-commit-action@v4
- uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: Apply php-cs-fixer changes

0 comments on commit 1c2aed1

Please sign in to comment.