Skip to content

Commit

Permalink
Merge pull request #149 from patchlevel/cleanup-workflows
Browse files Browse the repository at this point in the history
use ramsey/composer-install actions
  • Loading branch information
DanielBadura authored Dec 27, 2021
2 parents bd4b397 + 3a86105 commit a98d893
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 95 deletions.
21 changes: 2 additions & 19 deletions .github/workflows/coding-standard.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,26 +35,9 @@ jobs:
ini-values: memory_limit=-1
extensions: pdo_sqlite

- name: "Cache dependencies"
uses: "actions/cache@v2"
- uses: "ramsey/composer-install@v2"
with:
path: |
~/.composer/cache
vendor
key: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
restore-keys: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"

- name: "Install lowest dependencies"
if: ${{ matrix.dependencies == 'lowest' }}
run: "composer update --prefer-lowest --no-interaction --no-progress"

- name: "Install highest dependencies"
if: ${{ matrix.dependencies == 'highest' }}
run: "composer update --no-interaction --no-progress"

- name: "Install locked dependencies"
if: ${{ matrix.dependencies == 'locked' }}
run: "composer install --no-interaction --no-progress"
dependency-versions: ${{ matrix.dependencies }}

- name: "Coding Standard"
run: "vendor/bin/phpcs"
21 changes: 2 additions & 19 deletions .github/workflows/mutation-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,26 +34,9 @@ jobs:
php-version: "${{ matrix.php-version }}"
ini-values: memory_limit=-1

- name: "Cache dependencies"
uses: "actions/cache@v2"
- uses: "ramsey/composer-install@v2"
with:
path: |
~/.composer/cache
vendor
key: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
restore-keys: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"

- name: "Install lowest dependencies"
if: ${{ matrix.dependencies == 'lowest' }}
run: "composer update --prefer-lowest --no-interaction --no-progress"

- name: "Install highest dependencies"
if: ${{ matrix.dependencies == 'highest' }}
run: "composer update --no-interaction --no-progress"

- name: "Install locked dependencies"
if: ${{ matrix.dependencies == 'locked' }}
run: "composer install --no-interaction --no-progress"
dependency-versions: ${{ matrix.dependencies }}

- name: "Infection"
run: "vendor/bin/infection"
Expand Down
21 changes: 2 additions & 19 deletions .github/workflows/phpstan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,26 +35,9 @@ jobs:
ini-values: memory_limit=-1
extensions: pdo_sqlite

- name: "Cache dependencies"
uses: "actions/cache@v2"
- uses: "ramsey/composer-install@v2"
with:
path: |
~/.composer/cache
vendor
key: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
restore-keys: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"

- name: "Install lowest dependencies"
if: ${{ matrix.dependencies == 'lowest' }}
run: "composer update --prefer-lowest --no-interaction --no-progress"

- name: "Install highest dependencies"
if: ${{ matrix.dependencies == 'highest' }}
run: "composer update --no-interaction --no-progress"

- name: "Install locked dependencies"
if: ${{ matrix.dependencies == 'locked' }}
run: "composer install --no-interaction --no-progress"
dependency-versions: ${{ matrix.dependencies }}

- name: "PHPStan"
run: "vendor/bin/phpstan analyse"
21 changes: 2 additions & 19 deletions .github/workflows/phpunit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,26 +44,9 @@ jobs:
ini-values: memory_limit=-1
extensions: pdo_sqlite

- name: "Cache dependencies"
uses: "actions/cache@v2"
- uses: "ramsey/composer-install@v2"
with:
path: |
~/.composer/cache
vendor
key: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
restore-keys: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"

- name: "Install lowest dependencies"
if: ${{ matrix.dependencies == 'lowest' }}
run: "composer update --prefer-lowest --no-interaction --no-progress"

- name: "Install highest dependencies"
if: ${{ matrix.dependencies == 'highest' }}
run: "composer update --no-interaction --no-progress"

- name: "Install locked dependencies"
if: ${{ matrix.dependencies == 'locked' }}
run: "composer install --no-interaction --no-progress"
dependency-versions: ${{ matrix.dependencies }}

- name: "Tests"
run: "vendor/bin/phpunit --coverage-clover=clover.xml --coverage-text"
21 changes: 2 additions & 19 deletions .github/workflows/psalm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,26 +35,9 @@ jobs:
ini-values: memory_limit=-1
extensions: pdo_sqlite

- name: "Cache dependencies"
uses: "actions/cache@v2"
- uses: "ramsey/composer-install@v2"
with:
path: |
~/.composer/cache
vendor
key: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"
restore-keys: "php-${{ matrix.php-version }}-${{ matrix.dependencies }}"

- name: "Install lowest dependencies"
if: ${{ matrix.dependencies == 'lowest' }}
run: "composer update --prefer-lowest --no-interaction --no-progress"

- name: "Install highest dependencies"
if: ${{ matrix.dependencies == 'highest' }}
run: "composer update --no-interaction --no-progress"

- name: "Install locked dependencies"
if: ${{ matrix.dependencies == 'locked' }}
run: "composer install --no-interaction --no-progress"
dependency-versions: ${{ matrix.dependencies }}

- name: "psalm"
run: "vendor/bin/psalm --shepherd --stats"

0 comments on commit a98d893

Please sign in to comment.