Skip to content

Commit

Permalink
Add github action
Browse files Browse the repository at this point in the history
  • Loading branch information
wobqqq committed Apr 19, 2024
1 parent 883c548 commit 088c05b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 18 deletions.
19 changes: 2 additions & 17 deletions .github/workflows/php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,23 +17,8 @@ jobs:
steps:
- uses: actions/checkout@v3

- name: Validate composer.json and composer.lock
run: composer validate --strict

- name: Cache Composer packages
id: composer-cache
uses: actions/cache@v3
with:
path: vendor
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }}
restore-keys: |
${{ runner.os }}-php-
- name: Install dependencies
run: composer install --prefer-dist --no-progress

# Add a test script to composer.json, for instance: "test": "vendor/bin/phpunit"
# Docs: https://getcomposer.org/doc/articles/scripts.md

# - name: Run test suite
# run: composer run-script test
- name: Code debug
run: composer project.debug
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"scripts": {
"code.cs-fixer": "php-cs-fixer --diff fix",
"code.phpstan": "vendor/bin/phpstan analyse --memory-limit=512M",
"code.fix_and_analyse": [
"project.debug": [
"@code.cs-fixer",
"@code.phpstan"
]
Expand Down

0 comments on commit 088c05b

Please sign in to comment.