Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add new dependency analysis #86

Merged
merged 1 commit into from
Aug 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -95,10 +95,13 @@ jobs:
coverage: "none"
extensions: "${{ env.PHP_EXTENSIONS }}"
php-version: "${{ matrix.php-version }}"
tools: "composer-require-checker, composer-unused, flex"
tools: "flex"

- name: "Remove require-dev section in composer.json"
run: "composer config --unset require-dev"

- name: "Add shipmonk/composer-dependency-analyser to composer.json"
run: "composer require --dev --no-install --no-plugins --no-scripts shipmonk/composer-dependency-analyser"

- name: "Install composer dependencies"
uses: "ramsey/composer-install@v3"
Expand All @@ -107,11 +110,8 @@ jobs:
with:
dependency-versions: "${{ matrix.dependencies }}"

- name: "Run maglnet/composer-require-checker"
run: "composer-require-checker check"

- name: "Run composer-unused/composer-unused"
run: "composer-unused"
- name: "Run dependency analysis"
run: "vendor/bin/composer-dependency-analyser"

static-code-analysis:
name: "Static Code Analysis (PHP${{ matrix.php-version }} | Deps: ${{ matrix.dependencies }} | SF${{ matrix.symfony }})"
Expand Down
7 changes: 7 additions & 0 deletions composer-dependency-analyser.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?php

use ShipMonk\ComposerDependencyAnalyser\Config\Configuration;

return (new Configuration())
->addPathToExclude(__DIR__ . '/tests')
;
1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"phpunit/phpunit": "^9.6.17",
"psalm/plugin-phpunit": "^0.18.4",
"setono/code-quality-pack": "^2.7",
"shipmonk/composer-dependency-analyser": "^1.6",
"sylius/sylius": "~1.12.13",
"symfony/debug-bundle": "^5.4 || ^6.4 || ^7.0",
"symfony/dotenv": "^5.4 || ^6.4 || ^7.0",
Expand Down