Skip to content

Update dependabot config #161

Update dependabot config

Update dependabot config #161

Workflow file for this run

name: Code Style
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
on:
pull_request:
paths-ignore:
- 'docs/**'
- 'README.md'
- 'CHANGELOG.md'
- '.gitignore'
- '.gitattributes'
- 'psalm.xml'
jobs:
cs-fix:
name: PHP CS Fixer and Rector
runs-on: ubuntu-latest
permissions:
contents: write # Required to push automated CS fixes to the pull request branch.
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- name: Install PHP
uses: shivammathur/setup-php@f3e473d116dcccaddc5834248c87452386958240 # 2.37.2
with:
php-version: 8.2
tools: composer:v2
coverage: none
- name: Install Composer dependencies
uses: ramsey/composer-install@65e4f84970763564f46a70b8a54b90d033b3bdda # 4.0.0
- name: Run PHP CS Fixer
run: ./vendor/bin/php-cs-fixer fix --config=.php-cs-fixer.php
- name: Run Rector
run: ./vendor/bin/rector --output-format=github
- name: Configure Git credentials
env:
GH_TOKEN: ${{ github.token }}
run: git config --global credential.helper '!f() { echo username=x-access-token; echo password=$GH_TOKEN; }; f'
- name: Commit changes
run: |
git add -- '*.php'
if git diff --cached --quiet; then
exit 0
fi
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git commit -m "Apply PHP CS Fixer and Rector changes (CI)"
git push