Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: fix-code-style | |
on: | |
push: | |
jobs: | |
fix-code-style: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
token: ${{ secrets.PAT }} | |
ref: ${{ github.head_ref }} | |
- name: Setup PHP | |
uses: shivammathur/setup-php@v2 | |
- name: Copy .env | |
run: php -r "file_exists('.env') || copy('.env.example', '.env');" | |
- name: Create Database | |
run: | | |
mkdir -p database | |
touch database/database.sqlite | |
- name: Install dependencies | |
env: | |
DB_CONNECTION: sqlite | |
DB_DATABASE: database/database.sqlite | |
run: | | |
composer install --no-interaction | |
- name: Run Pint | |
run: ./vendor/bin/pint | |
- name: Pull changes | |
run: git pull | |
- name: Commit changes | |
uses: stefanzweifel/git-auto-commit-action@v4 | |
with: | |
commit_message: 'chore: fix code style' | |
token: ${{ secrets.PAT }} | |
ref: ${{ github.head_ref }} | |