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

Configured excludes are ignored when specifying paths in the command #651

Open
pelmered opened this issue Jun 27, 2023 · 0 comments
Open

Comments

@pelmered
Copy link

Q A
Bug report? yes (in my opinion)
Feature request? I would say it is a bug
Library version 2.8.0

Description
When specifying paths in the command, the excludes configured in the config file is ignored.

Use case
We run PHP insights on PRs, but we only want to run the insights on the files that has been changed in the PR and not the whole project. We use PHP Insights in a GitHub Action with the following configuration to accomplish this:

      - uses: dorny/paths-filter@v2
        id: filter
        with:
          list-files: shell
          filters: |
            php:
            - added|modified: '**.php'

      -   name: Fix code style
          run: php artisan insights ${{ steps.filter.outputs.php_files }} --fix --no-interaction --ansi --format=github-action

The problem is that we specify a few paths that should be in our excluded in out configuration, but this seems to be ignored when the files are passed to the insights command. I think they should be excluded according to the config even if you specify them explicitly in the command.

Maybe it would be good to add an option for this to avoid breaking the existing behavior?

We use Laravel 10.13.5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant