Skip to content

Commit db2c20e

Browse files
committed
minor #1551 Remove the composer cache from the CI workflows (rosier)
This PR was merged into the main branch. Discussion ---------- Remove the composer cache from the CI workflows I think there is little benefit anymore for this repository to have a composer cache in the CI workflows. With composer v2 the dependencies are downloaded in parallel which is a lot faster than composer v1. This makes the performance gains from the cache small since it also takes time to setup and save or restore the cache. Also the chance for a cache hit is low: - This repository has low traffic and the cache expires after a week which reduces the chance for a cache hit. - Every branch / PR get it's own cache which again reduces the chance for a cache hit. So I purpose to remove the composer cache to simplify the workflows. Replaces: #1538 Commits ------- a4baa11 Remove the composer cache from the CI workflows
2 parents 2456e31 + a4baa11 commit db2c20e

File tree

2 files changed

+0
-23
lines changed

2 files changed

+0
-23
lines changed

.github/workflows/lint.yaml

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -44,17 +44,6 @@ jobs:
4444
php-version: ${{ matrix.php-version }}
4545
tools: composer:v2
4646

47-
- name: "Set composer cache directory"
48-
id: composer-cache
49-
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
50-
51-
- name: "Cache composer"
52-
uses: actions/cache@v4
53-
with:
54-
path: ${{ steps.composer-cache.outputs.dir }}
55-
key: ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }}
56-
restore-keys: ${{ runner.os }}-composer-
57-
5847
- name: "Install dependencies"
5948
run: composer install --ansi --no-interaction --no-progress
6049

.github/workflows/tests.yaml

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -47,18 +47,6 @@ jobs:
4747
- name: "Add PHPUnit matcher"
4848
run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
4949

50-
- name: "Set composer cache directory"
51-
id: composer-cache
52-
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
53-
shell: bash
54-
55-
- name: "Cache composer"
56-
uses: actions/cache@v4
57-
with:
58-
path: ${{ steps.composer-cache.outputs.dir }}
59-
key: ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }}
60-
restore-keys: ${{ runner.os }}-composer-
61-
6250
- name: "Install dependencies"
6351
run: composer install --ansi --no-interaction --no-progress
6452

0 commit comments

Comments
 (0)