Skip to content

Commit 42c8476

Browse files
heiglandreasscheb
authored andcommitted
Remove psalm from most installations
As Psalm is only used in one single job it can be removed in general and then reinstalled when it is actually required before it is executed. This process allows to keep Psalm in the dev-dependencies so that constributors still have it available but in CI-runs it needs not to be installed when it is not executed.
1 parent 0a5575e commit 42c8476

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

.github/actions/setup-build/action.yaml

+4
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,10 @@ runs:
6666
shell: bash
6767
run: composer require ${{ inputs.composer-require }} --dev --no-update --working-dir=${{ inputs.composer-working-dir }}
6868

69+
- name: "Remove Psalm from dependencies"
70+
shell: bash
71+
run: composer remove --dev vimeo/psalm
72+
6973
- name: "Validate composer.json"
7074
shell: bash
7175
run: composer validate --no-check-publish --no-check-lock --working-dir=${{ inputs.composer-working-dir }}

.github/workflows/ci.yaml

+3-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,9 @@ jobs:
3636

3737
- name: "Psalm"
3838
if: always()
39-
run: vendor/bin/psalm
39+
run: |
40+
composer require -W --dev vimeo/psalm:^5.0
41+
vendor/bin/psalm
4042
4143
unit-tests:
4244
name: "Unit Tests - PHP ${{ matrix.php-version }}, Sf ${{ matrix.symfony-version }}${{ matrix.dependency-versions && format(', Deps: {0}', matrix.dependency-versions) }}"

0 commit comments

Comments
 (0)