FIX: code-format-check(added Update Psalm Configuration for GitHub Ac… #12
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: Code Format Check | |
on: | |
pull_request: | |
branches: | |
- main | |
jobs: | |
check-code-format: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Set up PHP | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: '8.1' | |
extensions: mbstring | |
- name: Install Composer dependencies | |
run: composer install --no-interaction --no-progress --prefer-dist | |
- name: Run PHPLint | |
run: php ./vendor/bin/phplint | |
- name: Run PHP_CodeSniffer | |
run: php ./vendor/bin/phpcs --standard=./configs/phpcs.xml ./app | |
- name: Update Psalm Configuration for GitHub Actions | |
run: | | |
sed -i 's|../psalm/stubs.php|/home/runner/work/CodeIgniter4-template/CodeIgniter4-template/psalm/stubs.php|' ./configs/psalm.xml | |
- name: Run Psalm | |
run: php ./vendor/bin/psalm --config=./configs/psalm.xml |