Skip to content

Commit 6f59ec5

Browse files
committed
use different phpsetup in github action
1 parent 1f15fe2 commit 6f59ec5

File tree

2 files changed

+13
-5
lines changed

2 files changed

+13
-5
lines changed

.github/workflows/php.yml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,21 +14,28 @@ jobs:
1414
- name: Checkout
1515
uses: actions/checkout@v4
1616

17+
- name: Get composer cache directory
18+
id: composer-cache
19+
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
20+
1721
- name: Cache Composer dependencies
1822
uses: actions/cache@v4
1923
with:
2024
path: /tmp/composer-cache
2125
key: ${{ runner.os }}-${{ hashFiles('**/composer.lock') }}
2226

23-
- name: Setup PHP
24-
uses: php-actions/composer@v6
27+
- name: Setup PHP with tools
28+
uses: shivammathur/setup-php@v2
2529
with:
26-
php_version: ${{ matrix.php-versions }}
27-
command: update
30+
php-version: '8.3'
31+
tools: composer:v2
2832

2933
- name: Validate Composer
3034
run: composer validate --strict
3135

36+
- name: Install dependencies
37+
run: composer install --prefer-dist
38+
3239
- name: PHP Lint
3340
run: composer lint
3441

.wp-env.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{
22
"core": null,
3-
"plugins": ["."]
3+
"plugins": ["."],
4+
"phpVersion": "8.3"
45
}

0 commit comments

Comments
 (0)