Skip to content

Commit b52862e

Browse files
committed
chore: add composer cache to style checks
1 parent b940f93 commit b52862e

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

.github/workflows/php-package.yml

+10-1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ name: PHP Package
22
env:
33
PHAR_TOOL_VERSION: 1.4.0
44
PHAR_TOOL_REPOSITORY: clue/phar-composer
5+
DEFAULT_PHP_VERSION: 8.3
56
on:
67
push:
78
pull_request:
@@ -15,8 +16,16 @@ jobs:
1516
- name: Setup PHP
1617
uses: shivammathur/setup-php@v2
1718
with:
18-
php-version: 8.2
19+
php-version: ${{ env.DEFAULT_PHP_VERSION }}
1920
tools: composer:v2
21+
- name: Composer Cache
22+
id: composer-cache
23+
run: |
24+
echo "cache_directory=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
25+
- uses: actions/cache@v4
26+
with:
27+
path: ${{ steps.composer-cache.outputs.cache_directory }}
28+
key: ${{ runner.os }}-composer
2029
- run: composer install
2130
shell: bash
2231
- run: composer format:check

0 commit comments

Comments
 (0)